File tree 3 files changed +566
-0
lines changed
3 files changed +566
-0
lines changed Original file line number Diff line number Diff line change 58
58
else
59
59
echo "### Nothing to commit"
60
60
fi
61
+ generate-registry :
62
+ docker :
63
+ - image : cimg/python:3.10.2
64
+ working_directory : ~/mozilla/firefox-translations-models
65
+ steps :
66
+ - add_ssh_keys :
67
+ fingerprints :
68
+ - " 11:60:82:e2:71:39:67:44:07:4c:16:8f:3d:89:6d:db"
69
+ - run :
70
+ name : Installing git lfs
71
+ command : |
72
+ sudo apt-get update
73
+ sudo apt-get install -y git-lfs
74
+ sudo git lfs install
75
+ - checkout
76
+ - run :
77
+ name : Updating model registry
78
+ command : |
79
+ python scripts/generate-registry.py
80
+ - run :
81
+ name : Showing results
82
+ command : |
83
+ git add registry.json
84
+ git --no-pager diff --staged registry.json
85
+ - run :
86
+ name : Pushing results
87
+ command : |
88
+ git config user.email "ci-models-evaluation@firefox-translations"
89
+ git config user.name "CircleCI evaluation job"
90
+ git add registry.json
91
+
92
+ if [[ $(git status --porcelain) ]]; then
93
+ echo "### Commiting results"
94
+ git commit -m "Update model registry [skip ci]"
95
+ git push --set-upstream origin "$CIRCLE_BRANCH"
96
+ else
97
+ echo "### Nothing to commit"
98
+ fi
99
+
61
100
62
101
workflows :
63
102
version : 2
@@ -76,3 +115,10 @@ workflows:
76
115
ignore :
77
116
- /pull\/[0-9]+/
78
117
- main
118
+ - generate-registry :
119
+ filters :
120
+ branches :
121
+ # Forked pull requests have CIRCLE_BRANCH set to pull/XXX
122
+ ignore :
123
+ - /pull\/[0-9]+/
124
+ - main
You can’t perform that action at this time.
0 commit comments