From a25f777e1a81a3ba90c1152a79fc3f84b41a452e Mon Sep 17 00:00:00 2001 From: TomaSajt <62384384+TomaSajt@users.noreply.github.com> Date: Sun, 15 Sep 2024 23:49:23 +0200 Subject: [PATCH] ember-cli: remove mkYarnPackage usage --- pkgs/by-name/em/ember-cli/package.json | 182 ------------------------- pkgs/by-name/em/ember-cli/package.nix | 32 +++-- 2 files changed, 20 insertions(+), 194 deletions(-) delete mode 100644 pkgs/by-name/em/ember-cli/package.json diff --git a/pkgs/by-name/em/ember-cli/package.json b/pkgs/by-name/em/ember-cli/package.json deleted file mode 100644 index 48cd3aa8543b0..0000000000000 --- a/pkgs/by-name/em/ember-cli/package.json +++ /dev/null @@ -1,182 +0,0 @@ -{ - "name": "ember-cli", - "version": "5.3.0", - "description": "Command line tool for developing ambitious ember.js apps", - "keywords": [ - "app", - "app-kit", - "blockchain", - "cli", - "ember", - "ember-app-kit", - "ember.js", - "kit" - ], - "homepage": "https://cli.emberjs.com/release/", - "bugs": { - "url": "https://github.com/ember-cli/ember-cli/issues" - }, - "repository": { - "type": "git", - "url": "https://github.com/ember-cli/ember-cli.git" - }, - "license": "MIT", - "author": "Stefan Penner, Robert Jackson and ember-cli contributors", - "main": "lib/cli/index.js", - "bin": { - "ember": "./bin/ember" - }, - "scripts": { - "docs": "yuidoc", - "lint": "eslint . --cache", - "prepack": "yarn docs", - "test": "node --unhandled-rejections=strict tests/runner", - "test:all": "node --unhandled-rejections=strict tests/runner all", - "test:cover": "nyc --all --reporter=text --reporter=lcov node tests/runner all", - "test:debug": "node --unhandled-rejections=strict debug tests/runner", - "test:slow": "node --unhandled-rejections=strict tests/runner slow" - }, - "dependencies": { - "@babel/core": "^7.22.10", - "@pnpm/find-workspace-dir": "^6.0.2", - "broccoli": "^3.5.2", - "broccoli-builder": "^0.18.14", - "broccoli-concat": "^4.2.5", - "broccoli-config-loader": "^1.0.1", - "broccoli-config-replace": "^1.1.2", - "broccoli-debug": "^0.6.5", - "broccoli-funnel": "^3.0.8", - "broccoli-funnel-reducer": "^1.0.0", - "broccoli-merge-trees": "^4.2.0", - "broccoli-middleware": "^2.1.1", - "broccoli-slow-trees": "^3.1.0", - "broccoli-source": "^3.0.1", - "broccoli-stew": "^3.0.0", - "calculate-cache-key-for-tree": "^2.0.0", - "capture-exit": "^2.0.0", - "chalk": "^4.1.2", - "ci-info": "^3.8.0", - "clean-base-url": "^1.0.0", - "compression": "^1.7.4", - "configstore": "^5.0.1", - "console-ui": "^3.1.2", - "core-object": "^3.1.5", - "dag-map": "^2.0.2", - "diff": "^5.1.0", - "ember-cli-is-package-missing": "^1.0.0", - "ember-cli-lodash-subset": "^2.0.1", - "ember-cli-normalize-entity-name": "^1.0.0", - "ember-cli-preprocess-registry": "^5.0.1", - "ember-cli-string-utils": "^1.1.0", - "ensure-posix-path": "^1.1.1", - "execa": "^5.1.1", - "exit": "^0.1.2", - "express": "^4.18.1", - "filesize": "^10.0.8", - "find-up": "^5.0.0", - "find-yarn-workspace-root": "^2.0.0", - "fixturify-project": "^2.1.1", - "fs-extra": "^11.1.1", - "fs-tree-diff": "^2.0.1", - "get-caller-file": "^2.0.5", - "git-repo-info": "^2.1.1", - "glob": "^8.1.0", - "heimdalljs": "^0.2.6", - "heimdalljs-fs-monitor": "^1.1.1", - "heimdalljs-graph": "^1.0.0", - "heimdalljs-logger": "^0.1.10", - "http-proxy": "^1.18.1", - "inflection": "^2.0.1", - "inquirer": "^9.1.5", - "is-git-url": "^1.0.0", - "is-language-code": "^3.1.0", - "isbinaryfile": "^5.0.0", - "leek": "0.0.24", - "lodash.template": "^4.5.0", - "markdown-it": "^13.0.1", - "markdown-it-terminal": "^0.4.0", - "minimatch": "^7.4.3", - "morgan": "^1.10.0", - "nopt": "^3.0.6", - "npm-package-arg": "^10.1.0", - "os-locale": "^5.0.0", - "p-defer": "^3.0.0", - "portfinder": "^1.0.32", - "promise-map-series": "^0.3.0", - "promise.hash.helper": "^1.0.8", - "quick-temp": "^0.1.8", - "remove-types": "^1.0.0", - "resolve": "^1.22.1", - "resolve-package-path": "^4.0.3", - "safe-stable-stringify": "^2.4.3", - "sane": "^5.0.1", - "semver": "^7.3.5", - "silent-error": "^1.1.1", - "sort-package-json": "^1.57.0", - "symlink-or-copy": "^1.3.1", - "temp": "0.9.4", - "testem": "^3.10.1", - "tiny-lr": "^2.0.0", - "tree-sync": "^2.1.0", - "uuid": "^9.0.0", - "walk-sync": "^3.0.0", - "watch-detector": "^1.0.2", - "workerpool": "^6.4.0", - "yam": "^1.0.0" - }, - "devDependencies": { - "@octokit/rest": "^19.0.7", - "broccoli-plugin": "^4.0.3", - "broccoli-test-helper": "^2.0.0", - "chai": "^4.3.7", - "chai-as-promised": "^7.1.1", - "chai-files": "^1.4.0", - "chai-jest-snapshot": "^2.0.0", - "ember-cli-blueprint-test-helpers": "^0.19.2", - "ember-cli-internal-test-helpers": "^0.9.1", - "eslint": "^8.44.0", - "eslint-config-prettier": "^8.9.0", - "eslint-plugin-chai-expect": "^3.0.0", - "eslint-plugin-mocha": "^10.1.0", - "eslint-plugin-n": "^16.0.1", - "eslint-plugin-prettier": "^4.2.1", - "fixturify": "^3.0.0", - "jsdom": "^21.1.1", - "latest-version": "^5.1.0", - "mocha": "^10.0.0", - "nock": "^13.3.0", - "nyc": "^15.1.0", - "prettier": "2.8.7", - "release-it": "^15.10.0", - "rimraf": "^3.0.2", - "strip-ansi": "^6.0.0", - "supertest": "^6.3.1", - "testdouble": "^3.18.0", - "tmp": "^0.2.1", - "websocket": "^1.0.32", - "which": "3.0.1", - "yuidoc-ember-cli-theme": "^1.0.4", - "yuidocjs": "0.10.2" - }, - "engines": { - "node": ">= 16" - }, - "publishConfig": { - "registry": "https://registry.npmjs.org" - }, - "release-it": { - "git": { - "tagName": "v${version}" - }, - "github": { - "draft": true, - "release": true, - "tokenRef": "GITHUB_AUTH" - } - }, - "trackingCode": "UA-49225444-1", - "volta": { - "node": "16.19.1", - "yarn": "1.22.19" - } -} diff --git a/pkgs/by-name/em/ember-cli/package.nix b/pkgs/by-name/em/ember-cli/package.nix index 86f627be950e5..a80a6e56ae784 100644 --- a/pkgs/by-name/em/ember-cli/package.nix +++ b/pkgs/by-name/em/ember-cli/package.nix @@ -1,28 +1,36 @@ -{ lib -, mkYarnPackage -, fetchFromGitHub -, fetchYarnDeps +{ + lib, + stdenvNoCC, + fetchFromGitHub, + fetchYarnDeps, + yarnConfigHook, + yarnInstallHook, + nodejs, }: -let +stdenvNoCC.mkDerivation (finalAttrs: { pname = "ember-cli"; version = "5.3.0"; + src = fetchFromGitHub { owner = "ember-cli"; repo = "ember-cli"; - rev = "v${version}"; + rev = "refs/tags/v${finalAttrs.version}"; hash = "sha256-xkMsPE+iweIV14m4kE4ytEp4uHMJW6gr+n9oJblr4VQ="; }; -in -mkYarnPackage { - inherit pname version src; offlineCache = fetchYarnDeps { - yarnLock = src + "/yarn.lock"; + yarnLock = finalAttrs.src + "/yarn.lock"; hash = "sha256-QgT2JFvMupJo+pJc13n2lmHMZkROJRJWoozCho3E6+c="; }; - packageJSON = ./package.json; + strictDeps = true; + + nativeBuildInputs = [ + yarnConfigHook + yarnInstallHook + nodejs + ]; meta = with lib; { homepage = "https://github.com/ember-cli/ember-cli"; @@ -32,4 +40,4 @@ mkYarnPackage { platforms = platforms.all; mainProgram = "ember"; }; -} +})