source_creation #19369
Workflow file for this run
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 is a basic workflow to help you get started with Actions | |
name: source_creation | |
# Controls when the workflow will run | |
on: | |
schedule: | |
- cron: "* 0/4 * * *" | |
workflow_dispatch: | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
tag: ["weekly-builds"] | |
branch: ["main"] | |
steps: | |
- name: Run a multi-line script | |
run: | | |
git clone https://github.com/FreeCAD/FreeCAD | |
touch freecad_version.txt | |
wget https://raw.githubusercontent.com/FreeCAD/FreeCAD-Bundle/${GITHUB_REF##*/}/make_version_file.py | |
cd FreeCAD | |
git checkout ${{ matrix.branch }} | |
git submodule update --init | |
python ../make_version_file.py ../freecad_version.txt | |
git archive HEAD -o ../freecad_source.tar | |
git submodule foreach --recursive \ | |
"git archive HEAD --prefix=\$path/ -o \$sha1.tar && \ | |
tar -A -f \$toplevel/../freecad_source.tar \$sha1.tar && \ | |
rm \$sha1.tar" | |
gzip ../freecad_source.tar | |
- name: Upload binaries to release | |
uses: svenstaro/upload-release-action@v2 | |
with: | |
repo_token: ${{ secrets.GITHUB_TOKEN }} | |
file: freecad* | |
tag: ${{ matrix.tag }} | |
overwrite: true | |
file_glob: true |