-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
242 create gh actions to generate machine readable codes (#256)
* first try to create action for github actions * install the missing deps dictoxml * sudo * xml,txt files * Fix push Add permissions to push * xml,txt files * push only on push * xml,txt files --------- Co-authored-by: antoineMerleEUM <[email protected]> Co-authored-by: Enrico Fucile <[email protected]>
- Loading branch information
1 parent
42f6590
commit e8b5cec
Showing
4 changed files
with
42 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
name: CI | ||
|
||
on: [ push ] | ||
|
||
permissions: | ||
contents: write | ||
|
||
jobs: | ||
make_xml: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: checkout | ||
uses: actions/checkout@v3 | ||
with: | ||
ref: ${{ github.ref }} | ||
- name: create xml files and push | ||
run: | | ||
sudo apt-get install -y python3-pip | ||
pip3 install dicttoxml | ||
python3 scripts/create_master_lists.py | ||
ls xml | ||
git config --global user.email "[email protected]" | ||
git config --global user.name "Enrico Fucile" | ||
git branch | ||
# Use of status --pocelain to check if files have been changed or not | ||
# If changes commit and push | ||
if [[ `git status --porcelain` ]]; then | ||
git add . | ||
git commit -m "xml,txt files" -a | ||
git push | ||
# if not, only print a message saying not commit | ||
else | ||
echo "No changes to commit" | ||
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters