Skip to content

Commit

Permalink
ci: revert merge of nightly branch
Browse files Browse the repository at this point in the history
The nightly branch is required because the GHA CI doesn't actually do
the build, and snapcraft requires it to be like this.

snapcraft consumes each branch and runs the `snapcraft.yaml`.
  • Loading branch information
justinmk committed Oct 3, 2024
1 parent e5d88e2 commit c92c152
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 15 deletions.
3 changes: 2 additions & 1 deletion .github/workflows/update-readme.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@ on:
- cron: '45 11 * * *'

jobs:
update_readme:
# Updates the timestamp in README.md, which triggers a "push" event.
bump_timestamp:
permissions:
contents: write
runs-on: ubuntu-latest
Expand Down
17 changes: 3 additions & 14 deletions snap/snapcraft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,28 +32,17 @@ apps:
desktop: usr/share/applications/nvim.desktop

parts:
name: publish ${{ matrix.nvimbranch }}
strategy:
fail-fast: false
matrix:
nvimbranch: [ stable, nightly ]
nvim:
source: https://github.com/neovim/neovim.git
override-pull: |
craftctl default
branch="${{ matrix.nvimbranch }}"
branch="stable"
git checkout tags/${branch} -b ${branch}
major="$(awk '/NVIM_VERSION_MAJOR/{gsub(")","",$2); print $2}' CMakeLists.txt)"
minor="$(awk '/NVIM_VERSION_MINOR/{gsub(")","",$2); print $2}' CMakeLists.txt)"
patch="$(awk '/NVIM_VERSION_PATCH/{gsub(")","",$2); print $2}' CMakeLists.txt)"
if [ stable = "${{ matrix.nvimbranch }}" ] ; then
version="v$major.$minor.$patch"
craftctl set version="${version}"
else
version_prefix="v$major.$minor.$patch"
git_described="$(git describe --first-parent 2> /dev/null | perl -lpe 's/v\d.\d.\d-//g' | perl -lpe 's/-/+/g')"
craftctl set version="${version_prefix}-${git_described}"
fi
version="v$major.$minor.$patch"
craftctl set version="${version}"
plugin: make
override-build: |
echo "Building on $SNAP_ARCH"
Expand Down

0 comments on commit c92c152

Please sign in to comment.