-
Notifications
You must be signed in to change notification settings - Fork 47
36 lines (30 loc) · 1005 Bytes
/
ci-drift.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
name: CI Drift
on:
pull_request:
branches: [main]
paths-ignore:
- "**.md"
concurrency:
group: ${{ github.workflow }}-${{ github.event_name }}-${{ github.ref }}
cancel-in-progress: true
jobs:
tailwind:
name: Tailwind
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3
- uses: actions/setup-node@64ed1c7eab4cce3362f8c340dee64e5eaeef8f7c # v3.6.0
with:
node-version: 16
cache: "npm"
- run: npm ci
- name: "Drift Detection: tailwind.config.js"
working-directory: mobile-app/app
run: |
export BEFORE=$(openssl sha1 styles.json | sed 's/^.* //')
npx create-tailwind-rn
export AFTER=$(openssl sha1 styles.json | sed 's/^.* //')
if [ "$BEFORE" != "$AFTER" ] ; then
echo "Drift detected: tailwind.config.js, please run 'npx create-tailwind-rn' in the /app directory."
exit 1
fi