Dry run for all jobs except when on main

This commit is contained in:
andrewc
2024-12-20 15:24:20 +10:00
parent 6e5a7fddc7
commit 80a2d5b1c0

View File

@@ -159,9 +159,9 @@ image:
pcb_attach=$(echo "['$fab_path/${name_n_rev}_PCB.pdf', '$CI_PROJECT_DIR/Fabrication/${name_n_rev}_JLC.zip']")
pcba_attach=$(echo "['$fab_path/${name_n_rev}_schematic.pdf', '$fab_path/${name_n_rev}_bom.csv', '$fab_path/${name_n_rev}-neo-pos_top.csv', '$fab_path/${name_n_rev}-neo-pos_bot.csv', '$fab_path/${name_n_rev}_ibom.html']")
DRY=""
if [[ $CI_COMMIT_BRANCH == "dev" ]]; then
DRY="--dry"
DRY="--dry"
if [[ $CI_COMMIT_BRANCH == "main" ]]; then
DRY=""
fi
poetry run python -m kintree_cli $DRY -p $CI_PROJECT_DIR/Fabrication/$f --assembly "{'ipn': '$name', 'rev': '$TAG', 'image': ['$pcb_im', '$pcba_im'], 'desc': '$desc_suffix', 'attachments': [$pcb_attach, $pcba_attach]}" --settings $KINTREE_SETT --digi_token token_storage.json || FAIL=1
done
@@ -289,7 +289,7 @@ inventree_job_dev:
- !reference [.dev_rules, rules]
script:
- !reference [.commands, boms]
inventree_job:
stage: inventree
needs: