Skip to content

Commit

Permalink
Update dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
sindresorhus committed Jul 26, 2024
1 parent 3d277f8 commit d7600b2
Show file tree
Hide file tree
Showing 5 changed files with 17 additions and 16 deletions.
4 changes: 4 additions & 0 deletions index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,20 +22,24 @@ export type OutputOptions = {
readonly rerunInterval?: number;
};

// eslint-disable-next-line unicorn/prevent-abbreviations
export type CacheConfGetOptions = {
/**
Get the item for the key provided without taking the `maxAge` of the item into account.
*/
readonly ignoreMaxAge?: boolean;
};

// eslint-disable-next-line unicorn/prevent-abbreviations
export type CacheConfSetOptions = {
/**
Number of milliseconds the cached value is valid.
*/
readonly maxAge?: number;
};

// TODO: Rename this in the next major version.
// eslint-disable-next-line unicorn/prevent-abbreviations
export type CacheConf<T extends Record<string, any> = Record<string, unknown>> = {
isExpired: (key: keyof T) => boolean;

Expand Down
5 changes: 0 additions & 5 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -118,11 +118,6 @@ alfy.fetch = async (url, options) => {
...options,
};

// TODO: Remove this in 2024.
if (options.query) {
throw new Error('The `query` option was renamed to `searchParams`.');
}

if (typeof url !== 'string') {
throw new TypeError(`Expected \`url\` to be a \`string\`, got \`${typeof url}\``);
}
Expand Down
4 changes: 2 additions & 2 deletions lib/update-notification.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ import {readPackageUp} from 'read-package-up';
import alfredNotifier from 'alfred-notifier';

export default async function updateNotification() {
const {package: pkg} = await readPackageUp();
const alfy = (pkg || {}).alfy || {};
const {package: package_} = await readPackageUp();
const alfy = package_?.alfy ?? {};

if (alfy.updateNotification !== false) {
alfredNotifier();
Expand Down
18 changes: 10 additions & 8 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
"description": "Create Alfred workflows with ease",
"license": "MIT",
"repository": "sindresorhus/alfy",
"funding": "https://github.com/sponsors/sindresorhus",
"type": "module",
"bin": {
"run-node": "./run-node.sh",
Expand All @@ -14,6 +15,7 @@
"types": "./index.d.ts",
"default": "./index.js"
},
"sideEffects": false,
"engines": {
"node": ">=18"
},
Expand Down Expand Up @@ -45,21 +47,21 @@
"alfred-notifier": "^0.2.3",
"cache-conf": "^0.6.0",
"clean-stack": "^5.2.0",
"conf": "^12.0.0",
"dot-prop": "^8.0.2",
"execa": "^8.0.1",
"got": "^13.0.0",
"conf": "^13.0.1",
"dot-prop": "^9.0.0",
"execa": "^9.3.0",
"got": "^14.4.2",
"hook-std": "^3.0.0",
"loud-rejection": "^2.2.0",
"read-package-up": "^11.0.0"
},
"devDependencies": {
"ava": "^5.3.1",
"ava": "^6.1.3",
"delay": "^6.0.0",
"nock": "^13.3.8",
"nock": "^13.5.4",
"tempfile": "^5.0.0",
"tsd": "^0.29.0",
"xo": "^0.56.0"
"tsd": "^0.31.1",
"xo": "^0.59.2"
},
"tsd": {
"compilerOptions": {
Expand Down
2 changes: 1 addition & 1 deletion readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ By adding `alfy-init` as `postinstall` and `alfy-cleanup` as `preuninstall` scri
"author": {
"name": "Sindre Sorhus",
"email": "[email protected]",
"url": "sindresorhus.com"
"url": "https://sindresorhus.com"
},
"scripts": {
"postinstall": "alfy-init",
Expand Down

0 comments on commit d7600b2

Please sign in to comment.