Skip to content

Commit e215578

Browse files
Merge pull request #272 from akv-platform/add-caching-for-node-dependencies
Implementation of node's caching
2 parents 9af8973 + cfe70f9 commit e215578

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

72 files changed

+136654
-17555
lines changed

.gitattributes

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1 @@
1-
# Set default behavior to automatically normalize line endings, and force everything to be LF, except for Windows batch files that require CRLF, so that if a repo is accessed in Unix via a file share from Windows, the scripts will work.
2-
* text=auto eol=lf
3-
*.{cmd,[cC][mM][dD]} text eol=crlf
4-
*.{bat,[bB][aA][tT]} text eol=crlf
51
.licenses/** -diff linguist-generated=true

.github/workflows/e2e-cache.yml

Lines changed: 101 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,101 @@
1+
name: e2e-cache
2+
3+
on:
4+
pull_request:
5+
paths-ignore:
6+
- '**.md'
7+
push:
8+
branches:
9+
- main
10+
- releases/*
11+
paths-ignore:
12+
- '**.md'
13+
14+
jobs:
15+
node-npm-depencies-caching:
16+
name: Test npm (Node ${{ matrix.node-version}}, ${{ matrix.os }})
17+
runs-on: ${{ matrix.os }}
18+
strategy:
19+
fail-fast: false
20+
matrix:
21+
os: [ubuntu-latest, windows-latest, macos-latest]
22+
node-version: [10, 12, 14]
23+
steps:
24+
- uses: actions/checkout@v2
25+
- name: Clean global cache
26+
run: npm cache clean --force
27+
- name: Setup Node
28+
uses: ./
29+
with:
30+
node-version: ${{ matrix.node-version }}
31+
cache: 'npm'
32+
- name: Install dependencies
33+
run: npm install
34+
- name: Verify node and npm
35+
run: __tests__/verify-node.sh "${{ matrix.node-version }}"
36+
shell: bash
37+
38+
node-yarn1-depencies-caching:
39+
name: Test yarn 1 (Node ${{ matrix.node-version}}, ${{ matrix.os }})
40+
runs-on: ${{ matrix.os }}
41+
strategy:
42+
fail-fast: false
43+
matrix:
44+
os: [ubuntu-latest, windows-latest, macos-latest]
45+
node-version: [10, 12, 14]
46+
steps:
47+
- uses: actions/checkout@v2
48+
- name: Yarn version
49+
run: yarn --version
50+
- name: Generate yarn file
51+
run: yarn install
52+
- name: Remove dependencies
53+
shell: pwsh
54+
run: Remove-Item node_modules -Force -Recurse
55+
- name: Clean global cache
56+
run: yarn cache clean
57+
- name: Setup Node
58+
uses: ./
59+
with:
60+
node-version: ${{ matrix.node-version }}
61+
cache: 'yarn'
62+
- name: Install dependencies
63+
run: yarn install
64+
- name: Verify node and yarn
65+
run: __tests__/verify-node.sh "${{ matrix.node-version }}"
66+
shell: bash
67+
68+
node-yarn2-depencies-caching:
69+
name: Test yarn 2 (Node ${{ matrix.node-version}}, ${{ matrix.os }})
70+
runs-on: ${{ matrix.os }}
71+
strategy:
72+
fail-fast: false
73+
matrix:
74+
os: [ubuntu-latest, windows-latest, macos-latest]
75+
node-version: [10, 12, 14]
76+
steps:
77+
- uses: actions/checkout@v2
78+
- name: Update yarn
79+
run: yarn set version berry
80+
- name: Yarn version
81+
run: yarn --version
82+
- name: Generate simple .yarnrc.yml
83+
run: |
84+
echo "nodeLinker: node-modules" >> .yarnrc.yml
85+
- name: Generate yarn file
86+
run: yarn install
87+
- name: Remove dependencies
88+
shell: pwsh
89+
run: Remove-Item node_modules -Force -Recurse
90+
- name: Clean global cache
91+
run: yarn cache clean --all
92+
- name: Setup Node
93+
uses: ./
94+
with:
95+
node-version: ${{ matrix.node-version }}
96+
cache: 'yarn'
97+
- name: Install dependencies
98+
run: yarn install
99+
- name: Verify node and yarn
100+
run: __tests__/verify-node.sh "${{ matrix.node-version }}"
101+
shell: bash

.github/workflows/versions.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,4 +123,4 @@ jobs:
123123
architecture: 'x86'
124124
- name: Verify node
125125
run: __tests__/verify-arch.sh "ia32"
126-
shell: bash
126+
shell: bash

.licensed.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ sources:
33

44
allowed:
55
- apache-2.0
6+
- 0bsd
67
- bsd-2-clause
78
- bsd-3-clause
89
- isc

.licenses/npm/@actions/cache.dep.yml

Lines changed: 20 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.licenses/npm/@actions/exec.dep.yml

Lines changed: 10 additions & 20 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.licenses/npm/@actions/glob-0.1.2.dep.yml

Lines changed: 20 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.licenses/npm/@actions/glob-0.2.0.dep.yml

Lines changed: 20 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.licenses/npm/@actions/http-client-1.0.11.dep.yml

Lines changed: 32 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.licenses/npm/@azure/abort-controller.dep.yml

Lines changed: 32 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.licenses/npm/@azure/core-asynciterator-polyfill.dep.yml

Lines changed: 32 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.licenses/npm/@azure/core-auth.dep.yml

Lines changed: 33 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.licenses/npm/@azure/core-http.dep.yml

Lines changed: 33 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)