@@ -12,15 +12,16 @@ See more in [Using PPM](#using-ppm).
1212
1313There are a few things you should double check before publishing:
1414
15- - Your ` package.json ` file has ` name ` , ` description ` , and ` repository ` fields.
16- - Your ` package.json ` ` name ` is URL Safe, as in it's not an emoji or special character.
17- - Your ` package.json ` file has a ` version ` field with a value of ` "0.0.0" ` .
18- - Your ` package.json ` ` version ` field is [ Semver V2] ( https://semver.org/spec/v2.0.0.html ) compliant.
19- - Your ` package.json ` file has an ` engines ` field that contains an entry for
20- ` atom ` such as: ` "engines": {"atom": ">=1.0.0 <2.0.0"} ` .
2115- Your package has a ` README.md ` file at the root.
22- - Your ` repository ` URL in the ` package.json ` file is the same as the URL of
23- your repository.
16+ - Your ` package.json ` file:
17+ - has ` name ` "URL Safe" field, as in it's not an emoji or special character.
18+ - has ` description ` field.
19+ - has ` repository ` field containing the URL of your repository.
20+ - has ` version ` field with a value of ` "0.0.0" ` before the first release, in
21+ any case it needs to be [ Semver V2] ( https://semver.org/spec/v2.0.0.html )
22+ compliant.
23+ - has ` engine ` field that contains an entry for ` atom ` such as:
24+ ` "engines": {"atom": ">=1.0.0 <2.0.0"} ` .
2425- Your package is in a Git repository that has been pushed to
2526 [ GitHub] ( https://github.com ) . Follow [ this guide] ( https://help.github.com/articles/importing-a-git-repository-using-the-command-line/ )
2627 if your package isn't already on GitHub.
@@ -34,54 +35,47 @@ do that by visiting `https://web.pulsar-edit.dev/packages/your-package-name` to
3435see if the package already exists. If it does, update your package's name to
3536something that is available before proceeding.
3637
37- Now let's review what the ` pulsar -p publish ` command does:
38+ Now, run the following commands from your package folder to publish it:
39+
40+ ``` sh
41+ $ pulsar -p login
42+ $ pulsar -p publish minor
43+ ```
44+
45+ ` pulsar -p login ` will let you create and set an API token in your keychain to
46+ permit interacting with GitHub API
47+
48+ ` pulsar -p publish minor ` command does:
3849
39501 . Registers the package name on Pulsar Package Repository if it is being
4051 published for the first time.
41- 2 . Updates the ` version ` field in the ` package.json ` file and commits it.
52+ 2 . Updates the ` version ` field in the ` package.json ` file applying the ` minor `
53+ version increase (details below) and commits it.
42543 . Creates a new [ Git tag] ( https://git-scm.com/book/en/Git-Basics-Tagging ) for
4355 the version being published.
44564 . Pushes the tag and current branch up to GitHub.
45575 . Updates Pulsar Package Repository with the new version being published.
4658
47- Now run the following commands to publish your package:
48-
49- ``` sh
50- $ cd path-to-your-package
51- $ pulsar -p publish minor
52- ```
53-
54- <!-- TODO: Rewrite this Section once Authentication Information is Public -->
55-
56- If this is the first package you are publishing, the ` pulsar -p publish ` command
57- may prompt you for your GitHub username and password. If you have two-factor
58- authentication enabled, use a [ personal access token] ( https://help.github.com/articles/creating-a-personal-access-token-for-the-command-line/ )
59- in lieu of a password. This is required to publish and you only need to enter
60- this information the first time you publish. The credentials are stored securely
61- in your [ keychain] ( < https://en.wikipedia.org/wiki/Keychain_(software) > ) once you
62- login.
63-
6459Your package is now published and available on Pulsar Package Repository. Head
6560on over to ` https://web.pulsar-edit.dev/packages/your-package-name ` to see your
6661package's page.
6762
63+ #### Version increase type
64+
6865With ` pulsar -p publish ` , you can bump the version and publish by using
6966
7067``` sh
71- $ pulsar -p publish < version- type>
68+ $ pulsar -p publish < type>
7269```
7370
74- where ` version-type ` can be ` major ` , ` minor ` and ` patch ` .
75-
76- - ** MAJOR** version when you make incompatible API changes
77- - ** MINOR** version when you add functionality in a backwards compatible manner
78- - ** PATCH** version when you make backwards compatible bug fixes
71+ where ` type ` can be ` major ` , ` minor ` and ` patch ` .
7972
80- i.e. to bump a package from v1.** 0** .0 to v1.** 1** .0:
81-
82- ``` sh
83- $ pulsar -p publish minor
84- ```
73+ - ** major** version when you make incompatible API changes
74+ - e.g. version ` 1.0.0 ` will become ` 2.0.0 `
75+ - ** minor** version when you add functionality in a backwards compatible manner
76+ - e.g. version ` 1.0.0 ` will become ` 1.1.0 `
77+ - ** patch** version when you make backwards compatible bug fixes
78+ - e.g. version ` 1.0.0 ` will become ` 1.0.1 `
8579
8680Check out [ semantic versioning] ( https://semver.org/ ) to learn more about best
8781practices for versioning your package releases.
0 commit comments