mirror of
https://github.com/livebook-dev/livebook.git
synced 2025-03-04 02:43:09 +08:00
Add GH Actions workflow automatically building assets (#147)
This commit is contained in:
parent
b3661ed2f0
commit
b054ef07b3
1 changed files with 31 additions and 0 deletions
31
.github/workflows/assets.yaml
vendored
Normal file
31
.github/workflows/assets.yaml
vendored
Normal file
|
@ -0,0 +1,31 @@
|
|||
name: Assets build
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
jobs:
|
||||
main:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- name: Install Erlang & Elixir
|
||||
uses: erlef/setup-elixir@v1
|
||||
with:
|
||||
otp-version: '23.2'
|
||||
elixir-version: '1.11.3'
|
||||
# Note: we need to get Phoenix and LV because package.json points to them directly
|
||||
- name: Install mix dependencies
|
||||
run: mix deps.get
|
||||
- name: Install Node
|
||||
uses: actions/setup-node@v2
|
||||
with:
|
||||
node-version: '14.x'
|
||||
- name: Install npm dependencies
|
||||
run: npm ci --prefix assets
|
||||
- name: Build assets
|
||||
run: npm run deploy --prefix assets
|
||||
- name: Update assets
|
||||
uses: stefanzweifel/git-auto-commit-action@v4
|
||||
with:
|
||||
commit_message: Update assets
|
||||
file_pattern: priv/static
|
Loading…
Reference in a new issue