aboutsummaryrefslogtreecommitdiff
path: root/.github
diff options
context:
space:
mode:
Diffstat (limited to '.github')
-rw-r--r--.github/ISSUE_TEMPLATE/bug_report.yml13
-rw-r--r--.github/ISSUE_TEMPLATE/config.yml2
-rw-r--r--.github/ISSUE_TEMPLATE/lsp_bug_report.yml44
-rw-r--r--.github/actions/cache/action.yml19
-rw-r--r--.github/dependabot.yml8
-rw-r--r--.github/labeler.yml4
-rwxr-xr-x.github/scripts/build_universal_macos.sh21
-rw-r--r--.github/scripts/close_unresponsive.js55
-rw-r--r--.github/scripts/env.ps1 (renamed from .github/workflows/env.ps1)2
-rwxr-xr-x.github/scripts/install_deps.sh41
-rwxr-xr-x.github/scripts/install_deps_ubuntu.sh19
-rw-r--r--.github/scripts/remove-reviewers.js10
-rw-r--r--.github/scripts/remove_response_label.js (renamed from .github/scripts/unstale.js)0
-rw-r--r--.github/scripts/reviews.js122
-rw-r--r--.github/workflows/add-reviewers.yml6
-rw-r--r--.github/workflows/api-docs-check.yml18
-rw-r--r--.github/workflows/api-docs.yml74
-rw-r--r--.github/workflows/backport.yml17
-rw-r--r--.github/workflows/build.yml94
-rw-r--r--.github/workflows/ci.yml351
-rw-r--r--.github/workflows/codeql.yml33
-rw-r--r--.github/workflows/coverity.yml6
-rwxr-xr-x.github/workflows/env.sh68
-rw-r--r--.github/workflows/issue-open-check.yml34
-rw-r--r--.github/workflows/labeler.yml15
-rw-r--r--.github/workflows/lintcommit.yml22
-rw-r--r--.github/workflows/news.yml11
-rw-r--r--.github/workflows/notes.md27
-rw-r--r--.github/workflows/optional.yml41
-rw-r--r--.github/workflows/release.yml160
-rw-r--r--.github/workflows/remove-reviewers.yml5
-rw-r--r--.github/workflows/response.yml35
-rw-r--r--.github/workflows/stale.yml42
-rw-r--r--.github/workflows/test.yml342
-rw-r--r--.github/workflows/vim-patches.yml8
35 files changed, 915 insertions, 854 deletions
diff --git a/.github/ISSUE_TEMPLATE/bug_report.yml b/.github/ISSUE_TEMPLATE/bug_report.yml
index 5fd7bc37b6..c07ae66c6f 100644
--- a/.github/ISSUE_TEMPLATE/bug_report.yml
+++ b/.github/ISSUE_TEMPLATE/bug_report.yml
@@ -6,28 +6,33 @@ body:
- type: markdown
attributes:
value: |
- _Before reporting:_ search [existing issues](https://github.com/neovim/neovim/issues?q=is%3Aissue+is%3Aopen+label%3Abug) and check the [FAQ](https://github.com/neovim/neovim/wiki/FAQ). Usage questions such as "How do I...?" belong on the [Neovim Discourse](https://neovim.discourse.group/c/7-category/7) and will be closed.
+ *Before reporting:*
+ - Confirm the problem is reproducible on [**master**](https://github.com/neovim/neovim/releases/nightly) or [**latest stable**](https://github.com/neovim/neovim/releases/stable) release
+ - run `make distclean` when encountering build issues
+ - search [existing issues](https://github.com/neovim/neovim/issues?q=is%3Aissue+is%3Aopen+label%3Abug)
+ - check the [FAQ](https://github.com/neovim/neovim/wiki/FAQ)
+ Usage or "How to" questions belong on the [stackoverflow](https://vi.stackexchange.com/) and will be closed.
- type: textarea
attributes:
- label: "Describe the bug"
+ label: "Problem"
description: "Describe the current behavior. May include logs, images, or videos."
validations:
required: true
-
- type: textarea
attributes:
label: "Steps to reproduce"
description: |
- For build failures: list the exact steps including CMake flags (if any).
- For startup or shell-related problems: try `env -i TERM=ansi-256color "$(which nvim)"`.
+ - See [Minimal-reproduction-template](https://github.com/neovim/neovim/wiki/Minimal-reproduction-template) for how to create a minimal configuration.
+ - Please do **not** include a package manager in the reproduction steps.
placeholder: |
nvim --clean
:edit foo
yiwp
validations:
required: true
-
- type: textarea
attributes:
label: "Expected behavior"
diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml
index 1e717ba6c5..f25732f90d 100644
--- a/.github/ISSUE_TEMPLATE/config.yml
+++ b/.github/ISSUE_TEMPLATE/config.yml
@@ -1,5 +1,5 @@
blank_issues_enabled: false
contact_links:
- name: Question
- url: https://neovim.discourse.group/
+ url: https://vi.stackexchange.com/
about: Ask questions about configuration and usage of Neovim
diff --git a/.github/ISSUE_TEMPLATE/lsp_bug_report.yml b/.github/ISSUE_TEMPLATE/lsp_bug_report.yml
index 88867ce644..bdad12e412 100644
--- a/.github/ISSUE_TEMPLATE/lsp_bug_report.yml
+++ b/.github/ISSUE_TEMPLATE/lsp_bug_report.yml
@@ -6,27 +6,14 @@ body:
- type: markdown
attributes:
value: |
- _Before reporting:_ search [existing issues](https://github.com/neovim/neovim/issues?q=is%3Aissue+is%3Aopen+label%3Abug) and check the [FAQ](https://github.com/neovim/neovim/wiki/FAQ). Usage questions such as "How do I...?" or "Why isn't X language server/feature working?" belong on the [Neovim Discourse](https://neovim.discourse.group/c/7-category/7) and will be closed.
+ _Before reporting:_ search [existing issues](https://github.com/neovim/neovim/issues?q=is%3Aissue+is%3Aopen+label%3Abug) and check the [FAQ](https://github.com/neovim/neovim/wiki/FAQ). Usage questions or "Why isn't X language server/feature working?" belong on [stackoverflow](https://vi.stackexchange.com/) and will be closed.
- - type: input
- attributes:
- label: "Neovim version (nvim -v)"
- placeholder: "0.6.0 commit db1b0ee3b30f"
- validations:
- required: true
- - type: input
- attributes:
- label: "Language server name/version"
- placeholder: "rls 0.5.2"
- validations:
- required: true
- - type: input
+ - type: textarea
attributes:
- label: "Operating system/version"
- placeholder: "emacs 23"
+ label: "Problem"
+ description: "Describe the bug caused by the Nvim LSP client."
validations:
required: true
-
- type: textarea
attributes:
label: 'Steps to reproduce using "nvim -u minimal_init.lua"'
@@ -46,7 +33,7 @@ body:
pattern = pattern,
callback = function(args)
local match = vim.fs.find(root_markers, { path = args.file, upward = true })[1]
- local root_dir = match and vim.fn.fnamemodify(match, ':p:h') or vim.NIL
+ local root_dir = match and vim.fn.fnamemodify(match, ':p:h') or nil
vim.lsp.start({
name = 'bugged-ls',
cmd = cmd,
@@ -65,14 +52,29 @@ body:
_Note_: if the issue is with an autocompletion or other LSP plugin, report to that plugin's issue tracker.
validations:
required: true
-
- type: textarea
attributes:
label: "Expected behavior"
description: "Describe the behavior you expect. May include logs, images, or videos."
- - type: textarea
+
+ - type: input
+ attributes:
+ label: "Neovim version (nvim -v)"
+ placeholder: "0.6.0 commit db1b0ee3b30f"
+ validations:
+ required: true
+ - type: input
+ attributes:
+ label: "Language server name/version"
+ placeholder: "rls 0.5.2"
+ validations:
+ required: true
+ - type: input
attributes:
- label: "Actual behavior"
+ label: "Operating system/version"
+ placeholder: "emacs 23"
+ validations:
+ required: true
- type: input
attributes:
diff --git a/.github/actions/cache/action.yml b/.github/actions/cache/action.yml
index 858045c02a..d668c7a7cc 100644
--- a/.github/actions/cache/action.yml
+++ b/.github/actions/cache/action.yml
@@ -3,20 +3,31 @@ description: "This action caches neovim dependencies"
runs:
using: "composite"
steps:
- - run: echo "CACHE_KEY=${{ github.job }}-${{ github.base_ref }}" >> $GITHUB_ENV
+ - run: echo "CACHE_KEY=${{ github.workflow }}" >> $GITHUB_ENV
+ shell: bash
+
+ - run: echo "CACHE_KEY=${{ github.job }}" >> $GITHUB_ENV
shell: bash
- if: ${{ matrix }}
run: echo "CACHE_KEY=$CACHE_KEY-${{ join(matrix.*, '-') }}" >> $GITHUB_ENV
shell: bash
+ - if: ${{ matrix.build }}
+ run: echo "CACHE_KEY=$CACHE_KEY-${{ join(matrix.build.*, '-') }}" >> $GITHUB_ENV
+ shell: bash
+
+ - id: image
+ run: echo "version=$ImageVersion" >> $GITHUB_OUTPUT
+ shell: bash
+
# Avoid using '**/CMakeLists.txt' (or any pattern starting with '**/') even
# if it makes the expression below simpler. hashFiles() has a timer that
# will fail the job if it times out, which can happen if there are too many
# files to search through.
- uses: actions/cache@v3
with:
- path: ${{ env.CACHE_NVIM_DEPS_DIR }}
- key: ${{ env.CACHE_KEY }}-${{ hashFiles('cmake**', 'ci/**',
- '.github/workflows/ci.yml', 'CMakeLists.txt',
+ path: .deps
+ key: ${{ env.CACHE_KEY }}-${{ steps.image.outputs.version }}-${{ hashFiles('cmake**',
+ '.github/**', 'CMakeLists.txt',
'runtime/CMakeLists.txt', 'src/nvim/**/CMakeLists.txt') }}
diff --git a/.github/dependabot.yml b/.github/dependabot.yml
new file mode 100644
index 0000000000..e96fd5286f
--- /dev/null
+++ b/.github/dependabot.yml
@@ -0,0 +1,8 @@
+version: 2
+updates:
+ - package-ecosystem: "github-actions"
+ directory: "/"
+ schedule:
+ interval: "daily"
+ commit-message:
+ prefix: "ci"
diff --git a/.github/labeler.yml b/.github/labeler.yml
index ad48287246..111fc5f373 100644
--- a/.github/labeler.yml
+++ b/.github/labeler.yml
@@ -2,10 +2,6 @@
- runtime/lua/vim/lsp.lua
- runtime/lua/vim/lsp/*
-"lua":
- - runtime/lua/**/*
- - src/nvim/lua/*
-
"tui":
- src/nvim/tui/tui.*
diff --git a/.github/scripts/build_universal_macos.sh b/.github/scripts/build_universal_macos.sh
new file mode 100755
index 0000000000..d07c395cd6
--- /dev/null
+++ b/.github/scripts/build_universal_macos.sh
@@ -0,0 +1,21 @@
+#!/bin/bash -e
+
+MACOSX_DEPLOYMENT_TARGET="$(sw_vers -productVersion | cut -f1 -d.)"
+export MACOSX_DEPLOYMENT_TARGET
+cmake -S cmake.deps -B .deps -G Ninja \
+ -D CMAKE_BUILD_TYPE=${NVIM_BUILD_TYPE} \
+ -D CMAKE_OSX_DEPLOYMENT_TARGET=${MACOSX_DEPLOYMENT_TARGET} \
+ -D CMAKE_OSX_ARCHITECTURES=arm64\;x86_64 \
+ -D CMAKE_FIND_FRAMEWORK=NEVER
+cmake --build .deps
+cmake -B build -G Ninja \
+ -D CMAKE_BUILD_TYPE=${NVIM_BUILD_TYPE} \
+ -D CMAKE_OSX_DEPLOYMENT_TARGET=${MACOSX_DEPLOYMENT_TARGET} \
+ -D CMAKE_OSX_ARCHITECTURES=arm64\;x86_64 \
+ -D CMAKE_FIND_FRAMEWORK=NEVER
+cmake --build build
+# Make sure we build everything for M1 as well
+for macho in build/bin/* build/lib/nvim/parser/*.so; do
+ lipo -info "$macho" | grep -q arm64 || exit 1
+done
+cpack --config build/CPackConfig.cmake
diff --git a/.github/scripts/close_unresponsive.js b/.github/scripts/close_unresponsive.js
new file mode 100644
index 0000000000..f0e8bbe93e
--- /dev/null
+++ b/.github/scripts/close_unresponsive.js
@@ -0,0 +1,55 @@
+function labeledEvent(data) {
+ return data.event === "labeled" && data.label.name === "needs:response";
+}
+
+const numberOfDaysLimit = 30;
+const close_message = `This has been closed since a request for information has \
+not been answered for ${numberOfDaysLimit} days. It can be reopened when the \
+requested information is provided.`;
+
+module.exports = async ({ github, context }) => {
+ const owner = context.repo.owner;
+ const repo = context.repo.repo;
+
+ const issues = await github.rest.issues.listForRepo({
+ owner: owner,
+ repo: repo,
+ labels: "needs:response",
+ });
+ const numbers = issues.data.map((e) => e.number);
+
+ for (const number of numbers) {
+ const events = await github.paginate(
+ github.rest.issues.listEventsForTimeline,
+ {
+ owner: owner,
+ repo: repo,
+ issue_number: number,
+ },
+ (response) => response.data.filter(labeledEvent)
+ );
+
+ const latest_response_label = events[events.length - 1];
+
+ const created_at = new Date(latest_response_label.created_at);
+ const now = new Date();
+ const diff = now - created_at;
+ const diffDays = diff / (1000 * 60 * 60 * 24);
+
+ if (diffDays > numberOfDaysLimit) {
+ github.rest.issues.update({
+ owner: owner,
+ repo: repo,
+ issue_number: number,
+ state: "closed",
+ });
+
+ github.rest.issues.createComment({
+ owner: owner,
+ repo: repo,
+ issue_number: number,
+ body: close_message,
+ });
+ }
+ }
+};
diff --git a/.github/workflows/env.ps1 b/.github/scripts/env.ps1
index 8ac267f2f9..d1dba5d558 100644
--- a/.github/workflows/env.ps1
+++ b/.github/scripts/env.ps1
@@ -1,3 +1,5 @@
+# This script enables Developer Command Prompt
+# See https://github.com/microsoft/vswhere/wiki/Start-Developer-Command-Prompt#using-powershell
$installationPath = vswhere.exe -latest -requires Microsoft.VisualStudio.Component.VC.Tools.x86.x64 -property installationPath
if ($installationPath -and (Test-Path "$installationPath\Common7\Tools\vsdevcmd.bat")) {
& "${env:COMSPEC}" /s /c "`"$installationPath\Common7\Tools\vsdevcmd.bat`" -arch=x64 -no_logo && set" | ForEach-Object {
diff --git a/.github/scripts/install_deps.sh b/.github/scripts/install_deps.sh
new file mode 100755
index 0000000000..9a782e9698
--- /dev/null
+++ b/.github/scripts/install_deps.sh
@@ -0,0 +1,41 @@
+#!/bin/bash
+
+while (($# > 0)); do
+ case $1 in
+ --test) # install test dependencies
+ TEST=1
+ shift
+ ;;
+ esac
+done
+
+os=$(uname -s)
+if [[ $os == Linux ]]; then
+ sudo apt-get update
+ sudo apt-get install -y build-essential cmake curl gettext ninja-build
+
+ if [[ $CC == clang ]]; then
+ DEFAULT_CLANG_VERSION=$(echo | clang -dM -E - | grep __clang_major | awk '{print $3}')
+ CLANG_VERSION=17
+ if ((DEFAULT_CLANG_VERSION >= CLANG_VERSION)); then
+ echo "Default clang version is $DEFAULT_CLANG_VERSION, which equal or larger than wanted version $CLANG_VERSION. Aborting!"
+ exit 1
+ fi
+
+ wget https://apt.llvm.org/llvm.sh
+ chmod +x llvm.sh
+ sudo ./llvm.sh $CLANG_VERSION
+ sudo update-alternatives --install /usr/bin/clang clang /usr/bin/clang-$CLANG_VERSION 100
+ sudo update-alternatives --set clang /usr/bin/clang-$CLANG_VERSION
+ fi
+
+ if [[ -n $TEST ]]; then
+ sudo apt-get install -y locales-all cpanminus attr libattr1-dev gdb
+ fi
+elif [[ $os == Darwin ]]; then
+ brew update --quiet
+ brew install ninja
+ if [[ -n $TEST ]]; then
+ brew install cpanminus
+ fi
+fi
diff --git a/.github/scripts/install_deps_ubuntu.sh b/.github/scripts/install_deps_ubuntu.sh
deleted file mode 100755
index 012409ba4a..0000000000
--- a/.github/scripts/install_deps_ubuntu.sh
+++ /dev/null
@@ -1,19 +0,0 @@
-#!/bin/bash
-
-PACKAGES=(
- autoconf
- automake
- build-essential
- cmake
- cpanminus
- curl
- gettext
- libtool-bin
- locales-all
- ninja-build
- pkg-config
- unzip
-)
-
-sudo apt-get update
-sudo apt-get install -y "${PACKAGES[@]}"
diff --git a/.github/scripts/remove-reviewers.js b/.github/scripts/remove-reviewers.js
index 40a8eca423..9e44e4ac86 100644
--- a/.github/scripts/remove-reviewers.js
+++ b/.github/scripts/remove-reviewers.js
@@ -1,18 +1,16 @@
-module.exports = async ({github, context}) => {
+module.exports = async ({ github, context }) => {
const requestedReviewers = await github.rest.pulls.listRequestedReviewers({
owner: context.repo.owner,
repo: context.repo.repo,
- pull_number: context.issue.number
+ pull_number: context.issue.number,
});
- const reviewers = requestedReviewers.data.users.map(e => e.login)
- const team_reviewers = requestedReviewers.data.teams.map(e => e.name);
+ const reviewers = requestedReviewers.data.users.map((e) => e.login);
github.rest.pulls.removeRequestedReviewers({
owner: context.repo.owner,
repo: context.repo.repo,
pull_number: context.issue.number,
reviewers: reviewers,
- team_reviewers: team_reviewers
});
-}
+};
diff --git a/.github/scripts/unstale.js b/.github/scripts/remove_response_label.js
index f645fca5cb..f645fca5cb 100644
--- a/.github/scripts/unstale.js
+++ b/.github/scripts/remove_response_label.js
diff --git a/.github/scripts/reviews.js b/.github/scripts/reviews.js
index cc6aaa1e8b..d28d91c2f6 100644
--- a/.github/scripts/reviews.js
+++ b/.github/scripts/reviews.js
@@ -1,108 +1,118 @@
-module.exports = async ({github, context}) => {
+module.exports = async ({ github, context }) => {
const pr_data = await github.rest.pulls.get({
owner: context.repo.owner,
repo: context.repo.repo,
- pull_number: context.issue.number
- })
- const labels = pr_data.data.labels.map(e => e.name)
+ pull_number: context.issue.number,
+ });
+ const labels = pr_data.data.labels.map((e) => e.name);
+ const reviewers = new Set();
+
+ if (labels.includes("api")) {
+ reviewers.add("bfredl");
+ reviewers.add("famiu");
+ }
- const reviewers = new Set()
- const team_reviewers = new Array()
- if (labels.includes('api')) {
- reviewers.add("bfredl")
- reviewers.add("muniter")
+ if (labels.includes("build")) {
+ reviewers.add("dundargoc");
+ reviewers.add("jamessan");
+ reviewers.add("justinmk");
}
- if (labels.includes('build')) {
- reviewers.add("jamessan")
- reviewers.add("justinmk")
+ if (labels.includes("ci")) {
+ reviewers.add("dundargoc");
+ reviewers.add("jamessan");
+ reviewers.add("justinmk");
}
- if (labels.includes('ci')) {
- team_reviewers.push('ci');
+ if (labels.includes("column")) {
+ reviewers.add("lewis6991");
}
- if (labels.includes('column')) {
- reviewers.add("lewis6991")
+ if (labels.includes("dependencies")) {
+ reviewers.add("jamessan");
}
- if (labels.includes('dependencies')) {
- reviewers.add("jamessan")
+ if (labels.includes("diagnostic")) {
+ reviewers.add("gpanders");
}
- if (labels.includes('diagnostic')) {
- reviewers.add("gpanders")
+ if (labels.includes("diff")) {
+ reviewers.add("lewis6991");
}
- if (labels.includes('diff')) {
- reviewers.add("lewis6991")
+ if (labels.includes("distribution")) {
+ reviewers.add("jamessan");
}
- if (labels.includes('distribution')) {
- reviewers.add("jamessan")
+ if (labels.includes("documentation")) {
+ reviewers.add("clason");
}
- if (labels.includes('documentation')) {
- reviewers.add("clason")
+ if (labels.includes("extmarks")) {
+ reviewers.add("bfredl");
}
- if (labels.includes('extmarks')) {
- reviewers.add("bfredl")
+ if (labels.includes("filetype")) {
+ reviewers.add("clason");
+ reviewers.add("gpanders");
+ reviewers.add("smjonas");
}
- if (labels.includes('filetype')) {
- reviewers.add("clason")
- reviewers.add("gpanders")
- reviewers.add("smjonas")
+ if (labels.includes("lsp")) {
+ reviewers.add("folke");
+ reviewers.add("MariaSolOs");
+ reviewers.add("mfussenegger");
}
- if (labels.includes('lsp')) {
- team_reviewers.push('lsp');
+ if (labels.includes("options")) {
+ reviewers.add("famiu");
}
- if (labels.includes('platform:nix')) {
- reviewers.add("teto")
+ if (labels.includes("platform:nix")) {
+ reviewers.add("teto");
}
- if (labels.includes('project-management')) {
- reviewers.add("bfredl")
- reviewers.add("justinmk")
+ if (labels.includes("project-management")) {
+ reviewers.add("bfredl");
+ reviewers.add("justinmk");
}
- if (labels.includes('refactor')) {
- reviewers.add("bfredl")
+ if (labels.includes("statusline")) {
+ reviewers.add("famiu");
}
- if (labels.includes('test')) {
- reviewers.add("justinmk")
+ if (labels.includes("test")) {
+ reviewers.add("justinmk");
}
- if (labels.includes('treesitter')) {
- team_reviewers.push('treesitter');
+ if (labels.includes("treesitter")) {
+ reviewers.add("bfredl");
+ reviewers.add("clason");
+ reviewers.add("lewis6991");
}
- if (labels.includes('typo')) {
- reviewers.add("dundargoc")
+ if (labels.includes("typo")) {
+ reviewers.add("dundargoc");
}
- if (labels.includes('ui')) {
- reviewers.add("bfredl")
+ if (labels.includes("ui")) {
+ reviewers.add("bfredl");
+ reviewers.add("famiu");
}
- if (labels.includes('vim-patch')) {
- reviewers.add("seandewar")
- reviewers.add("zeertzjq")
+ if (labels.includes("vim-patch")) {
+ reviewers.add("seandewar");
+ reviewers.add("zeertzjq");
}
// Remove person that opened the PR since they can't review themselves
- const pr_opener = pr_data.data.user.login
- reviewers.delete(pr_opener)
+ const pr_opener = pr_data.data.user.login;
+ reviewers.delete(pr_opener);
github.rest.pulls.requestReviewers({
owner: context.repo.owner,
repo: context.repo.repo,
pull_number: context.issue.number,
reviewers: Array.from(reviewers),
- team_reviewers: team_reviewers
});
-}
+};
diff --git a/.github/workflows/add-reviewers.yml b/.github/workflows/add-reviewers.yml
index f1abab5c53..22c68b6ef7 100644
--- a/.github/workflows/add-reviewers.yml
+++ b/.github/workflows/add-reviewers.yml
@@ -2,6 +2,7 @@ name: "Request reviews"
on:
pull_request_target:
types: [labeled, ready_for_review, reopened]
+ workflow_call:
jobs:
request-reviewer:
if: github.event.pull_request.state == 'open' && github.event.pull_request.draft == false
@@ -9,11 +10,10 @@ jobs:
permissions:
pull-requests: write
steps:
- - uses: actions/checkout@v3
+ - uses: actions/checkout@v4
- name: 'Request reviewers'
- uses: actions/github-script@v6
+ uses: actions/github-script@v7
with:
- github-token: ${{ secrets.TEAM_REVIEW }}
script: |
const script = require('./.github/scripts/reviews.js')
await script({github, context})
diff --git a/.github/workflows/api-docs-check.yml b/.github/workflows/api-docs-check.yml
deleted file mode 100644
index 0a57df7c33..0000000000
--- a/.github/workflows/api-docs-check.yml
+++ /dev/null
@@ -1,18 +0,0 @@
-name: Missing API docs
-on:
- pull_request:
- branches-ignore:
- - 'marvim/api-doc-update**'
- paths:
- - 'src/nvim/api/*.[ch]'
- - 'runtime/lua/**.lua'
- - 'runtime/doc/**'
-
-jobs:
- call-regen-api-docs:
- permissions:
- contents: write
- pull-requests: write
- uses: ./.github/workflows/api-docs.yml
- with:
- check_only: true
diff --git a/.github/workflows/api-docs.yml b/.github/workflows/api-docs.yml
index fa8a7dbca0..6f8fe107d2 100644
--- a/.github/workflows/api-docs.yml
+++ b/.github/workflows/api-docs.yml
@@ -1,74 +1,34 @@
-# Autogenerate the API docs on new commit to important branches
-# Also work as a check for PR's to not forget committing their doc changes
-# called from api-docs-check.yml
-name: Autogenerate API docs
+# Check if any PR needs to run the autogenerate script
+name: Autogenerate API docs and types
on:
- push:
+ pull_request:
+ types: [opened, synchronize, reopened, ready_for_review]
paths:
- 'src/nvim/api/*.[ch]'
+ - 'src/nvim/eval.lua'
- 'runtime/lua/**.lua'
- 'runtime/doc/**'
- branches:
- - 'master'
- - 'release-[0-9]+.[0-9]+'
- workflow_dispatch:
- workflow_call:
- inputs:
- check_only:
- type: boolean
- default: false
- required: false
jobs:
- regen-api-docs:
+ regen-api-docs-and-types:
runs-on: ubuntu-latest
+ if: github.event.pull_request.draft == false
permissions:
contents: write
pull-requests: write
- env:
- GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
steps:
- - uses: rhysd/action-setup-vim@v1
- with:
- neovim: true
- version: nightly
- - uses: actions/checkout@v3
- with:
- # Fetch depth 0 is required if called through workflow_call. In order
- # to create a PR we need to access other branches, which requires a
- # full clone.
- fetch-depth: 0
-
+ - uses: actions/checkout@v4
- name: Install dependencies
run: |
- sudo apt-get update
- sudo env DEBIAN_FRONTEND=noninteractive apt-get install -y doxygen python3 python3-msgpack
-
- - name: Setup git config
- run: |
- git config --global user.name 'marvim'
- git config --global user.email 'marvim@users.noreply.github.com'
-
- - run: printf 'DOC_BRANCH=marvim/api-doc-update/%s\n' ${GITHUB_REF#refs/heads/} >> $GITHUB_ENV
+ ./.github/scripts/install_deps.sh
+ sudo apt-get install -y doxygen python3-msgpack
+ - uses: ./.github/actions/cache
- name: Generate docs
- id: docs
- run: |
- git checkout -b ${DOC_BRANCH}
- python3 scripts/gen_vimdoc.py
- printf 'UPDATED_DOCS=%s\n' $([ -z "$(git diff)" ]; echo $?) >> $GITHUB_OUTPUT
-
- - name: FAIL, PR has not committed doc changes
- if: ${{ steps.docs.outputs.UPDATED_DOCS != 0 && inputs.check_only }}
- run: |
- echo "Job failed, run ./scripts/gen_vimdoc.py and commit your doc changes"
- echo "The doc generation produces the following changes:"
- git diff --color --exit-code
-
- - name: Automatic PR
- if: ${{ steps.docs.outputs.UPDATED_DOCS != 0 && !inputs.check_only }}
run: |
- git add -u
- git commit -m 'docs: regenerate [skip ci]'
- git push --force https://${GITHUB_ACTOR}:${GITHUB_TOKEN}@github.com/${GITHUB_REPOSITORY} ${DOC_BRANCH}
- gh pr create --draft --fill --base ${GITHUB_REF#refs/heads/} --head ${DOC_BRANCH} || true
+ make doc
+ if [ -n "$(git status --porcelain)" ]; then
+ echo "::error::Job failed, run 'make doc' and commit your doc changes."
+ echo "::error::The doc generation produces the following changes:"
+ git diff --color --exit-code
+ fi
diff --git a/.github/workflows/backport.yml b/.github/workflows/backport.yml
index 019fb20689..321cd02b0c 100644
--- a/.github/workflows/backport.yml
+++ b/.github/workflows/backport.yml
@@ -8,20 +8,9 @@ jobs:
contents: write
pull-requests: write
name: Backport Pull Request
- if: >
- github.repository_owner == 'neovim' && (
- github.event_name == 'pull_request_target' &&
- github.event.pull_request.merged
- )
+ if: github.event.pull_request.merged
runs-on: ubuntu-latest
steps:
- - uses: actions/checkout@v3
- with:
- # required to find all branches
- fetch-depth: 0
- ref: ${{ github.event.pull_request.head.sha }}
+ - uses: actions/checkout@v4
- name: Create backport PRs
- uses: zeebe-io/backport-action@v0
- with:
- github_token: ${{ secrets.GITHUB_TOKEN }}
- github_workspace: ${{ github.workspace }}
+ uses: korthout/backport-action@v2
diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml
new file mode 100644
index 0000000000..d6e11fcdcb
--- /dev/null
+++ b/.github/workflows/build.yml
@@ -0,0 +1,94 @@
+name: build
+on:
+ pull_request:
+ branches:
+ - 'master'
+ - 'release-[0-9]+.[0-9]+'
+ paths:
+ - '**.cmake'
+ - '**/CMakeLists.txt'
+ - '**/CMakePresets.json'
+ - 'cmake.*/**'
+ - '.github/**'
+
+concurrency:
+ group: ${{ github.workflow }}-${{ github.head_ref }}
+ cancel-in-progress: true
+
+env:
+ BIN_DIR: ${{ github.workspace }}/bin
+ INSTALL_PREFIX: ${{ github.workspace }}/nvim-install
+
+jobs:
+ macos-universal:
+ runs-on: macos-latest
+ timeout-minutes: 20
+ steps:
+ - uses: actions/checkout@v4
+ - run: ./.github/scripts/install_deps.sh
+ - run: printf 'NVIM_BUILD_TYPE=Release\n' >> $GITHUB_ENV
+
+ - name: Build universal binary
+ run: ./.github/scripts/build_universal_macos.sh
+
+ old-cmake:
+ name: Test oldest supported cmake
+ runs-on: ubuntu-22.04
+ timeout-minutes: 15
+ env:
+ CMAKE_URL: 'https://cmake.org/files/v3.10/cm