#Travis CI
Simple CI/CD for open source.
#Configuration
yaml
1# .travis.yml
2language: node_js
3node_js:
4 - "20"
5
6cache:
7 npm: true
8
9install:
10 - npm ci
11
12script:
13 - npm test
14 - npm run build
15
16deploy:
17 provider: pages
18 skip_cleanup: true
19 github_token: $GITHUB_TOKEN
20 local_dir: dist
21 on:
22 branch: main#Build Lifecycle
before_installinstallbefore_scriptscriptafter_success/after_failurebefore_deploydeployafter_deploy
#Matrix Builds
yaml
1language: node_js
2node_js:
3 - "18"
4 - "20"
5os:
6 - linux
7 - osx[!TIP] Pro Tip: Free for open source projects!