Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Redid how versioning works. #78

Merged
merged 4 commits into from
May 9, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 0 additions & 8 deletions .github/workflows/build-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,3 @@ jobs:
run: sudo apt-get install figlet
- name: 'Run Tests'
run: cd tests && ./commandline_args.sh
- name: 'Set CURRENTCOMMIT const'
run: echo 'const CURRENTCOMMIT* = "${{ github.sha }}"' > ./src/catniplib/global/currentcommit.nim
- name: 'Push changes'
run: |
git config --global user.name 'github-actions[bot]'
git config --global user.email 'github-actions[bot]@users.noreply.github.com'
git commit -am "Automatic build Number update"
git push
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,4 @@
catnip
*.exe
*.gz
src/catniplib/global/currentcommit.nim
2 changes: 2 additions & 0 deletions config.nims
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,12 @@ proc configure() =

task release, "Builds the project in release mode":
echo "\e[36;1mBuilding\e[0;0m in release mode"
exec &"./tests/git-commit-id.sh"
compile(true)

task debug, "Builds the project in debug mode":
echo "\e[36;1mBuilding\e[0;0m in debug mode"
exec &"./tests/git-commit-id.sh"
compile(false)

task install_cfg, "Installs the config files":
Expand Down
1 change: 0 additions & 1 deletion src/catniplib/global/currentcommit.nim

This file was deleted.

2 changes: 2 additions & 0 deletions tests/git-commit-id.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
#!/bin/sh
echo "const CURRENTCOMMIT* = \"$(git rev-parse HEAD)"\"\ > src/catniplib/global/currentcommit.nim
Loading