Merge pull request #21820 from dundargoc/release/0.8/ci

ci: sync release workflow with master
This commit is contained in:
dundargoc
2023-01-15 15:33:24 +01:00
committed by GitHub
8 changed files with 876 additions and 297 deletions

View File

@@ -52,7 +52,7 @@ jobs:
run: |
git checkout -b ${DOC_BRANCH}
python3 scripts/gen_vimdoc.py
printf '::set-output name=UPDATED_DOCS::%s\n' $([ -z "$(git diff)" ]; echo $?)
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 }}

View File

@@ -36,8 +36,10 @@ jobs:
id: build
run: |
CC=gcc-10 make CMAKE_BUILD_TYPE=${NVIM_BUILD_TYPE} CMAKE_EXTRA_FLAGS="-DCMAKE_INSTALL_PREFIX:PATH="
printf '::set-output name=version::%s\n' "$(./build/bin/nvim --version | head -n 3 | sed -z 's/\n/%0A/g')"
printf '::set-output name=release::%s\n' "$(./build/bin/nvim --version | head -n 1)"
printf 'version<<END\n' >> $GITHUB_OUTPUT
./build/bin/nvim --version | head -n 3 >> $GITHUB_OUTPUT
printf 'END\n' >> $GITHUB_OUTPUT
printf 'release=%s\n' "$(./build/bin/nvim --version | head -n 1)" >> $GITHUB_OUTPUT
make DESTDIR="$GITHUB_WORKSPACE/build/release/nvim-linux64" install
cd "$GITHUB_WORKSPACE/build/"
cpack -C $NVIM_BUILD_TYPE
@@ -246,16 +248,17 @@ jobs:
if [ "$TAG_NAME" != "nightly" ]; then
gh release create stable $PRERELEASE --notes-file "$RUNNER_TEMP/notes.md" --title "$SUBJECT" --target $GITHUB_SHA nvim-macos/* nvim-linux64/* appimage/* nvim-win64/*
fi
publish-winget:
needs: publish
runs-on: windows-latest
steps:
- if: github.event_name == 'push' || (github.event_name == 'workflow_dispatch' && github.event.inputs.tag_name != 'nightly')
name: Publish stable
uses: vedantmgoyal2009/winget-releaser@latest
uses: vedantmgoyal2009/winget-releaser@v1
with:
identifier: Neovim.Neovim
release-tag: ${{ github.event.inputs.tag_name || github.ref }}
release-tag: ${{ github.event.inputs.tag_name || github.ref_name }}
token: ${{ secrets.WINGET_TOKEN }}
- if: github.event_name == 'schedule' || (github.event_name == 'workflow_dispatch' && github.event.inputs.tag_name == 'nightly')
name: Get nightly version
@@ -264,10 +267,10 @@ jobs:
Invoke-WebRequest https://github.com/neovim/neovim/releases/download/nightly/nvim-win64.msi -OutFile setup.msi
Install-Module -Name 'Carbon.Windows.Installer' -Force
$VERSION = (Get-CMsi (Resolve-Path .\setup.msi).Path).ProductVersion
echo "::set-output name=version::$VERSION"
"version=$VERSION" >> $env:GITHUB_OUTPUT
- if: github.event_name == 'schedule' || (github.event_name == 'workflow_dispatch' && github.event.inputs.tag_name == 'nightly')
name: Publish nightly
uses: vedantmgoyal2009/winget-releaser@latest
uses: vedantmgoyal2009/winget-releaser@v1
with:
identifier: Neovim.Neovim.Nightly
version: ${{ steps.get-version.outputs.version }}

View File

@@ -40,8 +40,8 @@ jobs:
id: update-version
run: |
git checkout -b ${VERSION_BRANCH}
nvim -i NONE -u NONE --headless +'luafile scripts/vimpatch.lua' +q
printf '::set-output name=NEW_PATCHES::%s\n' $([ -z "$(git diff)" ]; echo $?)
nvim -V1 -es -i NONE +'luafile scripts/vimpatch.lua' +q
printf 'NEW_PATCHES=%s\n' $([ -z "$(git diff)" ]; echo $?) >> $GITHUB_OUTPUT
- name: Automatic PR
if: ${{ steps.update-version.outputs.NEW_PATCHES != 0 }}

View File

@@ -338,6 +338,7 @@ local function validate_link(node, bufnr, fname)
return helppage, tagname, ignored
end
-- TODO: port the logic from scripts/check_urls.vim
local function validate_url(text, fname)
local ignored = false
if vim.fs.basename(fname) == 'pi_netrw.txt' then

View File

@@ -35,7 +35,7 @@ usage() {
echo " -m {vim-revision} List previous (older) missing Vim patches."
echo " -M List all merged patch-numbers (at current v:version)."
echo " -p {vim-revision} Download and generate a Vim patch. vim-revision"
echo " can be a Vim version (8.0.xxx) or a Git hash."
echo " can be a Vim version (8.1.xxx) or a Git hash."
echo " -P {vim-revision} Download, generate and apply a Vim patch."
echo " -g {vim-revision} Download a Vim patch."
echo " -s [pr args] Create a vim-patch pull request."
@@ -466,7 +466,7 @@ submit_pr() {
patch_file="vim-${patch_file}.patch"
if [[ ! -f "${NVIM_SOURCE_DIR}/${patch_file}" ]]; then
continue
fi
fi
rm -- "${NVIM_SOURCE_DIR}/${patch_file}"
msg_ok "Removed '${NVIM_SOURCE_DIR}/${patch_file}'."
done
@@ -484,7 +484,7 @@ list_vimpatch_tokens() {
| grep -oE 'vim-patch:[^ ,{:]{7,}' \
| sort \
| uniq \
| sed -nE 's/^(vim-patch:([0-9]+\.[^ ]+|[0-9a-z]{7,7})).*/\1/p'
| sed -nE 's/^(vim-patch:([0-9]+\.[^ ]+|[0-9a-z]{7,7})).*/\1/p'
}
# Prints all patch-numbers (for the current v:version) for which there is
@@ -581,7 +581,7 @@ _set_missing_vimpatches() {
continue
fi
# Get commit hash, and optional info from line. This is used in
# Get commit hash, and optional info from line. This is used in
# extended mode, and when using e.g. '--format' manually.
vim_commit=${line%% *}
if [[ "$vim_commit" == "$line" ]]; then
@@ -624,7 +624,7 @@ show_vimpatches() {
if [[ "${runtime_commits[$vim_commit]-}" ]]; then
printf ' • %s (+runtime)\n' "${vim_commit}"
else
printf ' • %s\n' "${vim_commit}"
printf ' • %s\n' "${vim_commit}"
fi
done

View File

@@ -1,7 +1,7 @@
-- Updates version.c list of applied Vim patches.
--
-- Usage:
-- VIM_SOURCE_DIR=~/neovim/.vim-src/ nvim -i NONE -u NONE --headless +'luafile ./scripts/vimpatch.lua' +q
-- VIM_SOURCE_DIR=~/neovim/.vim-src/ nvim -V1 -es -i NONE +'luafile ./scripts/vimpatch.lua' +q
local nvim = vim.api
@@ -22,12 +22,13 @@ end
-- Generates the lines to be inserted into the src/version.c
-- `included_patches[]` definition.
local function gen_version_c_lines()
-- Set of merged Vim 8.0.zzzz patch numbers.
-- Set of merged Vim 8.1.zzzz patch numbers.
local merged_patch_numbers = {}
local highest = 0
for _, n in ipairs(vimpatch_sh_list_numbers()) do
n = tonumber(n)
if n then
merged_patch_numbers[tonumber(n)] = true
merged_patch_numbers[n] = true
highest = math.max(highest, n)
end
end

File diff suppressed because it is too large Load Diff

View File

@@ -14,7 +14,7 @@ extern char *longVersion;
// Values that change for a new release
#define VIM_VERSION_MAJOR 8
#define VIM_VERSION_MINOR 0
#define VIM_VERSION_MINOR 1
// Values based on the above
#define VIM_VERSION_MAJOR_STR STR(VIM_VERSION_MAJOR)