Skip to content

Commit

Permalink
Use npm instead of yarn (denoland#159)
Browse files Browse the repository at this point in the history
  • Loading branch information
lucacasonato authored and axetroy committed Sep 5, 2020
1 parent cf64faf commit d0e606a
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 16 deletions.
26 changes: 16 additions & 10 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,39 +23,45 @@ jobs:
with:
node-version: ${{ matrix.node }}

- name: Get npm cache directory
id: npm-cache
run: |
echo "::set-output name=dir::$(npm config get cache)"
- uses: actions/cache@v2
with:
path: "**/node_modules"
key: ${{ runner.os }}-modules-${{ hashFiles('**/yarn.lock') }}
path: ${{ steps.npm-cache.outputs.dir }}
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-node-
- name: Setup Deno
- name: Setup Deno
uses: denolib/setup-deno@master
with:
deno-version: ${{ matrix.deno }}

- name: Environment
run: |
node -v
yarn --version
npm -v
deno --version
- name: Install
run: yarn
run: npm i

- name: Check code format
run: yarn run check
run: npm run check

- name: Lint
run: yarn run lint
run: npm run lint

- name: Test
run: yarn run test
run: npm run test

- name: Compile
run: yarn run compile
run: npm run compile

- name: Package
run: yarn run build
run: npm run build

- name: Publish
if: |
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ out
# package lock
yarn.lock
package-json.lock
**/package-lock.json

# testing
coverage
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -169,15 +169,15 @@ Follow these steps to contribute, the community needs your strength.
```bash
$ git clone https://github.com/your_github_name/vscode_deno.git
$ cd vscode_deno
$ yarn
$ npm
```

3. Disable extension in Visual Studio Code if you have extension before

4. Compile the extension:

```bash
$ yarn compile # or `yarn watch` to automatically recompile on changes
$ npm run compile # or `npm run watch` to automatically recompile on changes
```

5. Start debug extension
Expand Down
8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "vscode-deno",
"displayName": "Deno",
"description": "Deno support for VSCode",
"version": "2.0.14",
"version": "2.0.15",
"publisher": "denoland",
"icon": "deno.png",
"galleryBanner": {
Expand Down Expand Up @@ -174,16 +174,16 @@
]
},
"scripts": {
"vscode:prepublish": "yarn compile",
"postinstall": "cd client && yarn && cd ../server && yarn && cd ../typescript-deno-plugin && yarn && cd .. && npm run installvscode",
"vscode:prepublish": "npm run compile",
"postinstall": "cd client && npm i && cd ../server && npm i && cd .. && npm run installvscode",
"installvscode": "npx vscode-install",
"watch": "tsc -b -w",
"compile": "tsc -b",
"check": "prettier \"**/*.md\" \"**/*.json\" \"**/*.ts\" \"**/*.yml\" --config ./.prettierrc.json --check",
"format": "prettier \"**/*.md\" \"**/*.json\" \"**/*.ts\" \"**/*.yml\" --config ./.prettierrc.json --write",
"test": "jest --coverage",
"test-coveralls": "jest --coverage --coverageReporters=text-lcov | coveralls",
"build": "npx vsce package -o ./vscode-deno.vsix --yarn",
"build": "npx vsce package -o ./vscode-deno.vsix",
"lint": "eslint . --ext .js,.jsx,.ts,.tsx"
},
"devDependencies": {
Expand Down

0 comments on commit d0e606a

Please sign in to comment.