Skip to content

Commit

Permalink
Updated CLI blueprints (#154)
Browse files Browse the repository at this point in the history
* chore: Updated latestVersions

* chore: Updated CONTRIBUTING

* chore: Updated fixtures

* chore: Added changeset

---------

Co-authored-by: ijlee2 <[email protected]>
  • Loading branch information
ijlee2 and ijlee2 authored Mar 7, 2025
1 parent f29b983 commit db9d9b8
Show file tree
Hide file tree
Showing 11 changed files with 55 additions and 60 deletions.
5 changes: 5 additions & 0 deletions .changeset/quiet-peaches-bake.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@codemod-utils/cli": patch
---

Updated latestVersions and CHANGELOG
6 changes: 2 additions & 4 deletions packages/cli/src/blueprints/CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,14 +81,13 @@ Here are some guidelines to help you and everyone else.

<details>

<summary>Publish package (for admins)</summary>
<summary>Publish package</summary>

1. Generate a [personal access token](https://github.com/settings/tokens/) in GitHub, with `repo` and `read:user` scopes enabled. This token will be used to retrieve pull request information.
1. Generate a [personal access token](https://github.com/settings/tokens/) in GitHub. Enable `repo` and `read:user` scopes if your repo is private. This token will be used to retrieve pull request information.

1. Run the `release:prepare` script. This removes changesets, updates package versions, and updates `CHANGELOG`s.

```sh
# From the workspace root
GITHUB_TOKEN=<YOUR_PERSONAL_ACCESS_TOKEN> pnpm release:prepare
```

Expand All @@ -97,7 +96,6 @@ Here are some guidelines to help you and everyone else.
1. Review the file changes. Commit them in a branch, then open a pull request to merge the changes to the `main` branch.
```sh
# From the workspace root
git checkout -b tag-0.1.2
git add .
git commit -m "Tagged 0.1.2"
Expand Down
20 changes: 10 additions & 10 deletions packages/cli/src/utils/blueprints/get-version.ts
Original file line number Diff line number Diff line change
@@ -1,26 +1,26 @@
import { decideVersion } from '@codemod-utils/blueprints';

const latestVersions = new Map([
['@changesets/cli', '2.27.12'],
['@changesets/cli', '2.28.1'],
['@changesets/get-github-info', '0.6.0'],
['@codemod-utils/ast-javascript', '1.2.13'],
['@codemod-utils/ast-javascript', '1.2.14'],
['@codemod-utils/ast-template', '1.1.8'],
['@codemod-utils/blueprints', '1.1.9'],
['@codemod-utils/ember', '2.0.4'],
['@codemod-utils/files', '2.0.8'],
['@codemod-utils/json', '1.1.14'],
['@codemod-utils/json', '1.1.15'],
['@codemod-utils/tests', '1.1.11'],
['@ijlee2-frontend-configs/eslint-config-node', '0.2.1'],
['@ijlee2-frontend-configs/prettier', '0.2.0'],
['@ijlee2-frontend-configs/typescript', '0.3.0'],
['@ijlee2-frontend-configs/eslint-config-node', '0.2.5'],
['@ijlee2-frontend-configs/prettier', '0.2.1'],
['@ijlee2-frontend-configs/typescript', '0.3.1'],
['@sondr3/minitest', '0.1.2'],
['@types/node', '18.19.75'],
['@types/node', '18.19.79'],
['@types/yargs', '17.0.33'],
['concurrently', '9.1.2'],
['eslint', '9.20.0'],
['eslint', '9.21.0'],
['pnpm', '9.15.5'],
['prettier', '3.5.0'],
['typescript', '5.7.3'],
['prettier', '3.5.3'],
['typescript', '5.8.2'],
['yargs', '17.7.2'],
]);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -81,14 +81,13 @@ Here are some guidelines to help you and everyone else.

<details>

<summary>Publish package (for admins)</summary>
<summary>Publish package</summary>

1. Generate a [personal access token](https://github.com/settings/tokens/) in GitHub, with `repo` and `read:user` scopes enabled. This token will be used to retrieve pull request information.
1. Generate a [personal access token](https://github.com/settings/tokens/) in GitHub. Enable `repo` and `read:user` scopes if your repo is private. This token will be used to retrieve pull request information.

1. Run the `release:prepare` script. This removes changesets, updates package versions, and updates `CHANGELOG`s.

```sh
# From the workspace root
GITHUB_TOKEN=<YOUR_PERSONAL_ACCESS_TOKEN> pnpm release:prepare
```

Expand All @@ -97,7 +96,6 @@ Here are some guidelines to help you and everyone else.
1. Review the file changes. Commit them in a branch, then open a pull request to merge the changes to the `main` branch.
```sh
# From the workspace root
git checkout -b tag-0.1.2
git add .
git commit -m "Tagged 0.1.2"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,24 +31,24 @@
"test": "mt tests --quiet"
},
"dependencies": {
"@codemod-utils/ast-javascript": "^1.2.13",
"@codemod-utils/ast-javascript": "^1.2.14",
"@codemod-utils/ast-template": "^1.1.8",
"@codemod-utils/blueprints": "^1.1.9",
"@codemod-utils/ember": "^2.0.4",
"@codemod-utils/files": "^2.0.8",
"@codemod-utils/json": "^1.1.14",
"@codemod-utils/json": "^1.1.15",
"yargs": "^17.7.2"
},
"devDependencies": {
"@changesets/cli": "^2.27.12",
"@changesets/cli": "^2.28.1",
"@changesets/get-github-info": "^0.6.0",
"@codemod-utils/tests": "^1.1.11",
"@ijlee2-frontend-configs/eslint-config-node": "^0.2.1",
"@ijlee2-frontend-configs/prettier": "^0.2.0",
"@ijlee2-frontend-configs/eslint-config-node": "^0.2.5",
"@ijlee2-frontend-configs/prettier": "^0.2.1",
"@sondr3/minitest": "^0.1.2",
"concurrently": "^9.1.2",
"eslint": "^9.20.0",
"prettier": "^3.5.0"
"eslint": "^9.21.0",
"prettier": "^3.5.3"
},
"engines": {
"node": "18.* || >= 20"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -81,14 +81,13 @@ Here are some guidelines to help you and everyone else.

<details>

<summary>Publish package (for admins)</summary>
<summary>Publish package</summary>

1. Generate a [personal access token](https://github.com/settings/tokens/) in GitHub, with `repo` and `read:user` scopes enabled. This token will be used to retrieve pull request information.
1. Generate a [personal access token](https://github.com/settings/tokens/) in GitHub. Enable `repo` and `read:user` scopes if your repo is private. This token will be used to retrieve pull request information.

1. Run the `release:prepare` script. This removes changesets, updates package versions, and updates `CHANGELOG`s.

```sh
# From the workspace root
GITHUB_TOKEN=<YOUR_PERSONAL_ACCESS_TOKEN> pnpm release:prepare
```

Expand All @@ -97,7 +96,6 @@ Here are some guidelines to help you and everyone else.
1. Review the file changes. Commit them in a branch, then open a pull request to merge the changes to the `main` branch.
```sh
# From the workspace root
git checkout -b tag-0.1.2
git add .
git commit -m "Tagged 0.1.2"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,15 +35,15 @@
"yargs": "^17.7.2"
},
"devDependencies": {
"@changesets/cli": "^2.27.12",
"@changesets/cli": "^2.28.1",
"@changesets/get-github-info": "^0.6.0",
"@codemod-utils/tests": "^1.1.11",
"@ijlee2-frontend-configs/eslint-config-node": "^0.2.1",
"@ijlee2-frontend-configs/prettier": "^0.2.0",
"@ijlee2-frontend-configs/eslint-config-node": "^0.2.5",
"@ijlee2-frontend-configs/prettier": "^0.2.1",
"@sondr3/minitest": "^0.1.2",
"concurrently": "^9.1.2",
"eslint": "^9.20.0",
"prettier": "^3.5.0"
"eslint": "^9.21.0",
"prettier": "^3.5.3"
},
"engines": {
"node": "18.* || >= 20"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -81,14 +81,13 @@ Here are some guidelines to help you and everyone else.

<details>

<summary>Publish package (for admins)</summary>
<summary>Publish package</summary>

1. Generate a [personal access token](https://github.com/settings/tokens/) in GitHub, with `repo` and `read:user` scopes enabled. This token will be used to retrieve pull request information.
1. Generate a [personal access token](https://github.com/settings/tokens/) in GitHub. Enable `repo` and `read:user` scopes if your repo is private. This token will be used to retrieve pull request information.

1. Run the `release:prepare` script. This removes changesets, updates package versions, and updates `CHANGELOG`s.

```sh
# From the workspace root
GITHUB_TOKEN=<YOUR_PERSONAL_ACCESS_TOKEN> pnpm release:prepare
```

Expand All @@ -97,7 +96,6 @@ Here are some guidelines to help you and everyone else.
1. Review the file changes. Commit them in a branch, then open a pull request to merge the changes to the `main` branch.
```sh
# From the workspace root
git checkout -b tag-0.1.2
git add .
git commit -m "Tagged 0.1.2"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,28 +33,28 @@
"test": "./build.sh --test && mt dist-for-testing --quiet"
},
"dependencies": {
"@codemod-utils/ast-javascript": "^1.2.13",
"@codemod-utils/ast-javascript": "^1.2.14",
"@codemod-utils/ast-template": "^1.1.8",
"@codemod-utils/blueprints": "^1.1.9",
"@codemod-utils/ember": "^2.0.4",
"@codemod-utils/files": "^2.0.8",
"@codemod-utils/json": "^1.1.14",
"@codemod-utils/json": "^1.1.15",
"yargs": "^17.7.2"
},
"devDependencies": {
"@changesets/cli": "^2.27.12",
"@changesets/cli": "^2.28.1",
"@changesets/get-github-info": "^0.6.0",
"@codemod-utils/tests": "^1.1.11",
"@ijlee2-frontend-configs/eslint-config-node": "^0.2.1",
"@ijlee2-frontend-configs/prettier": "^0.2.0",
"@ijlee2-frontend-configs/typescript": "^0.3.0",
"@ijlee2-frontend-configs/eslint-config-node": "^0.2.5",
"@ijlee2-frontend-configs/prettier": "^0.2.1",
"@ijlee2-frontend-configs/typescript": "^0.3.1",
"@sondr3/minitest": "^0.1.2",
"@types/node": "^18.19.75",
"@types/node": "^18.19.79",
"@types/yargs": "^17.0.33",
"concurrently": "^9.1.2",
"eslint": "^9.20.0",
"prettier": "^3.5.0",
"typescript": "^5.7.3"
"eslint": "^9.21.0",
"prettier": "^3.5.3",
"typescript": "^5.8.2"
},
"engines": {
"node": "18.* || >= 20"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -81,14 +81,13 @@ Here are some guidelines to help you and everyone else.

<details>

<summary>Publish package (for admins)</summary>
<summary>Publish package</summary>

1. Generate a [personal access token](https://github.com/settings/tokens/) in GitHub, with `repo` and `read:user` scopes enabled. This token will be used to retrieve pull request information.
1. Generate a [personal access token](https://github.com/settings/tokens/) in GitHub. Enable `repo` and `read:user` scopes if your repo is private. This token will be used to retrieve pull request information.

1. Run the `release:prepare` script. This removes changesets, updates package versions, and updates `CHANGELOG`s.

```sh
# From the workspace root
GITHUB_TOKEN=<YOUR_PERSONAL_ACCESS_TOKEN> pnpm release:prepare
```

Expand All @@ -97,7 +96,6 @@ Here are some guidelines to help you and everyone else.
1. Review the file changes. Commit them in a branch, then open a pull request to merge the changes to the `main` branch.
```sh
# From the workspace root
git checkout -b tag-0.1.2
git add .
git commit -m "Tagged 0.1.2"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,19 +37,19 @@
"yargs": "^17.7.2"
},
"devDependencies": {
"@changesets/cli": "^2.27.12",
"@changesets/cli": "^2.28.1",
"@changesets/get-github-info": "^0.6.0",
"@codemod-utils/tests": "^1.1.11",
"@ijlee2-frontend-configs/eslint-config-node": "^0.2.1",
"@ijlee2-frontend-configs/prettier": "^0.2.0",
"@ijlee2-frontend-configs/typescript": "^0.3.0",
"@ijlee2-frontend-configs/eslint-config-node": "^0.2.5",
"@ijlee2-frontend-configs/prettier": "^0.2.1",
"@ijlee2-frontend-configs/typescript": "^0.3.1",
"@sondr3/minitest": "^0.1.2",
"@types/node": "^18.19.75",
"@types/node": "^18.19.79",
"@types/yargs": "^17.0.33",
"concurrently": "^9.1.2",
"eslint": "^9.20.0",
"prettier": "^3.5.0",
"typescript": "^5.7.3"
"eslint": "^9.21.0",
"prettier": "^3.5.3",
"typescript": "^5.8.2"
},
"engines": {
"node": "18.* || >= 20"
Expand Down

0 comments on commit db9d9b8

Please sign in to comment.