Détail du package

sort-package-json-scripts

bluelovers110ISC1.1.27

a better sort package.json scripts, by default is follow npm lifecycle scripts

readme

README.md

a better sort package.json scripts, by default is follow npm lifecycle scripts

install

yarn add sort-package-json-scripts
yarn-tool add sort-package-json-scripts
import sortPackageJsonScripts from 'sort-package-json-scripts';

let ret = sortPackageJsonScripts({

    "lint": "npx eslint *.ts",

    "npm:publish": "npm publish",

    "prepublish:lockfile": "npx sync-lockfile .",
    "tsc:esm": "tsc -p tsconfig.esm.json",
    "ncu": "npx yarn-tool ncu -u",
    "sort-package-json": "npx yarn-tool sort",
    "test": "jest --coverage",
    "coverage": "npx nyc yarn run test",
    "test:mocha": "npx mocha --require ts-node/register \"!(node_modules)/*.{test,spec}.{ts,tsx}\"",
    "tsc:default": "tsc -p tsconfig.json",

    "prepublishOnly": "yarn run ncu && yarn run sort-package-json && yarn run test",

    "postpublish_": "git commit -m \"chore(release): publish\" .",
})

console.log(ret)
/*
{
    coverage: 'npx nyc yarn run test',
    lint: 'npx eslint *.ts',
    test: 'jest --coverage',
    'test:mocha': 'npx mocha --require ts-node/register "!(node_modules)/*.{test,spec}.{ts,tsx}"',
    'npm:publish': 'npm publish',
    'prepublish:lockfile': 'npx sync-lockfile .',
    prepublishOnly: 'yarn run ncu && yarn run sort-package-json && yarn run test',
    postpublish_: 'git commit -m "chore(release): publish" .',
    ncu: 'npx yarn-tool ncu -u',
    'sort-package-json': 'npx yarn-tool sort',
    'tsc:default': 'tsc -p tsconfig.json',
    'tsc:esm': 'tsc -p tsconfig.esm.json'
}
 */

changelog

Change Log

All notable changes to this project will be documented in this file. See Conventional Commits for commit guidelines.

1.1.27 (2024-05-03)

🛠 Build System

📌 Dependencies

1.1.26 (2024-02-28)

✨ Features

  • sort semver release type (df4aec1)

🚨 Tests

1.1.25 (2023-01-24)

✨ Features

🔖 Miscellaneous

1.1.24 (2022-11-14)

📌 Dependencies

1.1.23 (2022-10-28)

📌 Dependencies

1.1.22 (2022-10-01)

🔖 Miscellaneous

1.1.21 (2022-09-29)

🔖 Miscellaneous

1.1.20 (2022-09-27)

🔖 Miscellaneous

1.1.19 (2022-09-27)

📌 Dependencies

1.1.18 (2022-09-06)

📚 Documentation

🔖 Miscellaneous

1.1.17 (2022-08-26)

🔖 Miscellaneous

1.1.16 (2022-08-25)

✨ Features

🚨 Tests

  • snapshot: snapshots updated (50bff7c)

1.1.15 (2022-08-13)

🚨 Tests

  • update jest.config.js and deps (d1d501b)

🛠 Build System

1.1.14 (2022-07-31)

🚨 Tests

  • preset: use @bluelovers/jest-config (e239ecf)

1.1.13 (2022-05-11)

♻️ Chores

1.1.12 (2021-12-30)

✨ Features

🚨 Tests

1.1.11 (2021-12-16)

🔖 Miscellaneous

1.1.10 (2021-11-28)

📦 Code Refactoring

  • update import remove /core (9d3dc5f)

1.1.9 (2021-08-13)

♻️ Chores

1.1.8 (2021-07-11)

🛠 Build System

🔖 Miscellaneous

1.1.7 (2021-07-11)

🛠 Build System

1.1.6 (2021-06-02)

♻️ Chores

1.1.5 (2020-07-12)

♻️ Chores

1.1.4 (2020-07-03)

✨ Features

  • 調整 version 的順序 來配合 lerna 的執行順序 (ecc6e7f)

1.1.3 (2020-06-20)

🚨 Tests

  • snapshot: update snapshot (668573f)

♻️ Chores

1.1.2 (2020-06-20)

✨ Features

  • add preinstallOnly postinstallOnly preuninstallOnly postuninstallOnly prepareOnly (01c1354)

1.1.1 (2020-06-19)

🚨 Tests

1.0.12 (2020-06-19)

🔖 Miscellaneous

1.0.11 (2020-06-19)

✨ Features

🚨 Tests

♻️ Chores

🔖 Miscellaneous

1.0.10 (2020-06-06)

Note: Version bump only for package sort-package-json-scripts

1.0.9 (2020-05-23)

Note: Version bump only for package sort-package-json-scripts

1.0.8 (2020-05-10)

Note: Version bump only for package sort-package-json-scripts

1.0.7 (2020-04-28)

Note: Version bump only for package sort-package-json-scripts

1.0.6 (2020-04-28)

Note: Version bump only for package sort-package-json-scripts

1.0.5 (2020-04-08)

Bug Fixes

  • not defined key didn't follow script lifecycle, and put base key on first one (3c2565c)

1.0.4 (2020-04-07)

Code Refactoring

  • rename var name and split code (684a7d3)

Features

  • update snapshot and use is-plain-obj (4d63056)

BREAKING CHANGES

  • options name is changed

1.0.3 (2020-04-06)

Features

  • allow config sortPackageJsonScripts (6751350)