Skip to content

Commit

Permalink
Update Deno + dependencies
Browse files Browse the repository at this point in the history
Move imports into deno.json, as that's the most common place to put it nowadays.
  • Loading branch information
BrunoBernardino committed Oct 8, 2024
1 parent 1ffe19b commit 9fc703a
Show file tree
Hide file tree
Showing 12 changed files with 22 additions and 24 deletions.
2 changes: 1 addition & 1 deletion .dvmrc
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.44.1
1.46.3
2 changes: 1 addition & 1 deletion .github/workflows/cron-check-subscriptions.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
- uses: actions/checkout@v4
- uses: denoland/setup-deno@v1
with:
deno-version: v1.44.1
deno-version-file: .dvmrc
- env:
POSTGRESQL_HOST: ${{ secrets.POSTGRESQL_HOST }}
POSTGRESQL_USER: ${{ secrets.POSTGRESQL_USER }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/cron-cleanup.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
- uses: actions/checkout@v4
- uses: denoland/setup-deno@v1
with:
deno-version: v1.44.1
deno-version-file: .dvmrc
- env:
POSTGRESQL_HOST: ${{ secrets.POSTGRESQL_HOST }}
POSTGRESQL_USER: ${{ secrets.POSTGRESQL_USER }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ jobs:
- uses: actions/checkout@v4
- uses: denoland/setup-deno@v1
with:
deno-version: v1.44.1
deno-version-file: .dvmrc
- run: docker-compose pull
- uses: jpribyl/[email protected]
continue-on-error: true
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM denoland/deno:1.44.1
FROM denoland/deno:1.46.3

EXPOSE 8000

Expand Down
1 change: 1 addition & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ format:
test:
deno fmt --check
deno lint
deno check .
deno test --allow-net --allow-read --allow-env --check

.PHONY: migrate-db
Expand Down
13 changes: 11 additions & 2 deletions deno.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,15 @@
"deno.ns"
]
},
"importMap": "./import_map.json",
"lock": false
"lock": false,
"imports": {
"/": "./",
"./": "./",

"std/assert/equals": "jsr:@std/[email protected]/equals",
"std/assert/not-equals": "jsr:@std/[email protected]/not-equals",
"std/http/file-server": "jsr:@std/[email protected]/file-server",
"std/dotenv/load": "jsr:@std/[email protected]/load",
"deno/emit": "jsr:@deno/[email protected]"
}
}
12 changes: 0 additions & 12 deletions import_map.json

This file was deleted.

2 changes: 1 addition & 1 deletion lib/utils_test.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { assertEquals } from 'std/assert/assert-equals';
import { assertEquals } from 'std/assert/equals';
import { escapeHtml, generateRandomCode, jsonToFormUrlEncoded, splitArrayInChunks } from './utils.ts';

Deno.test('that escapeHtml works', () => {
Expand Down
2 changes: 1 addition & 1 deletion main_test.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { assertEquals } from 'std/assert/assert-equals';
import { assertEquals } from 'std/assert/equals';
import { abortController } from './main.ts';

const baseUrl = 'http://localhost:8000';
Expand Down
4 changes: 2 additions & 2 deletions public/ts/encryption_test.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { assertEquals } from 'std/assert/assert-equals';
import { assertNotEquals } from 'std/assert/assert-not-equals';
import { assertEquals } from 'std/assert/equals';
import { assertNotEquals } from 'std/assert/not-equals';
import { KeyPair } from '/lib/types.ts';
import Encryption from './encryption.ts';

Expand Down
2 changes: 1 addition & 1 deletion public/ts/utils_test.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { assertEquals } from 'std/assert/assert-equals';
import { assertEquals } from 'std/assert/equals';
import { dateDiffInDays, formatNumber, SupportedCurrencySymbol, validateEmail } from './utils.ts';

Deno.test('that dateDiffInDays works', () => {
Expand Down

0 comments on commit 9fc703a

Please sign in to comment.