Skip to content

Commit

Permalink
Merge pull request #551 from swrlab/dev/remove-uuid
Browse files Browse the repository at this point in the history
chore: update dependencies
  • Loading branch information
frytg authored Dec 27, 2023
2 parents 4ff2610 + 7e8fb6f commit 7b45041
Show file tree
Hide file tree
Showing 4 changed files with 197 additions and 470 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@ by [**SWR Audio Lab**](https://lab.swr.de/)

## Changelog

- 2023-12-27 - v1.2.1
- chore: update dependencies
- refact: remove `uuid` dependency
- chore!: upgrade minimum NodeJS version to `v18`

- 2023-12-18 - v1.2.0
- refact: optimize linter util to work with Yarn `>=v4`
- chore: upgrade default NodeJS version to `v20`
Expand Down
13 changes: 6 additions & 7 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
{
"name": "@swrlab/utils",
"version": "1.2.0",
"version": "1.2.1",
"description": "Wrapping common SWR Audio Lab utils",
"main": "./index.js",
"engines": {
"node": ">=16"
"node": ">=18"
},
"repository": {
"type": "git",
Expand All @@ -18,18 +18,17 @@
"lint": "eslint .",
"test": "mocha tests/**.js -r dotenv/config",
"outdated": "yarn upgrade-interactive",
"reinstall": "rm -rf node_modules && rm yarn.lock && yarn"
"reinstall": "rm -rf node_modules && rm yarn.lock && touch yarn.lock && yarn"
},
"author": "SWR Audio Lab <lab@swr.de>",
"license": "MIT",
"dependencies": {
"@google-cloud/storage": "^6.12.0",
"@google-cloud/storage": "^7.7.0",
"abort-controller": "^3.0.0",
"aws-sdk": "2.1520.0",
"aws-sdk": "2.1525.0",
"luxon": "3.4.4",
"node-crc": "swrlab/node-crc#v2.1.0",
"undici": "6.0.1",
"uuid": "9.0.1"
"undici": "6.2.1"
},
"devDependencies": {
"@swrlab/eslint-plugin-swr": "^0.3.0",
Expand Down
4 changes: 2 additions & 2 deletions packages/storage-wrapper/save.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
// load node utils
const os = require('os')
const pathUtil = require('path')
const { v4: uuidv4 } = require('uuid')
const { randomUUID } = require('crypto')

const saveLocalFile = (that, uri, buffer) =>
new Promise((resolve, reject) => {
Expand Down Expand Up @@ -59,7 +59,7 @@ module.exports = async function (uri, buffer, logPrefix, resumable) {
path = structure.join('/')

// save to local file
const tempFilePath = pathUtil.resolve(os.tmpdir(), uuidv4())
const tempFilePath = pathUtil.resolve(os.tmpdir(), randomUUID())
await saveLocalFile(this, tempFilePath, buffer)

// log progress
Expand Down
Loading

0 comments on commit 7b45041

Please sign in to comment.