4.2.0 • Published 3 months ago

projectz v4.2.0

Weekly downloads
1,512
License
Artistic-2.0
Repository
github
Last release
3 months ago

Stop wasting time syncing and updating your project's README and Package Files!

Used by over 300 repositories and 200 projects thus far!

Watch the talk.

Here's some of the things it can do:

npm

Running Projectz

Directly

Once installed locally, you can compile your project using projectz by running the following in your terminal:

npx projectz compile

Automatically

To make projectz more automatic, we recommended adding the direct command above to your build tool.

If you don't use a build tool, but do use npm, then you can add the following to your project's package.json file:

{
    "scripts": {
        "compile": "projectz compile",
        "posttest": "npm run compile"
    }
}

The compile script here is runnable via the command npm run-script compile and will compile your project with projectz.

The posttest script here automatically compiles your project with projectz after your tests have successfully completed, providing you use npm test to run your tests. This is a great place to put projectz as projectz only updates meta documents so won't affect your test, and will always run before a publish.

GitHub Rate Limiting

If you get a rate limit warning, you will need to add GITHUB_ACCESS_TOKEN (or a GITHUB_CLIENT_ID AND GITHUB_CLIENT_SECRET combination) to your environment. To do this:

  1. Create a personal access token for your computer at: https://github.com/settings/tokens
  2. Projectz needs the readonly/access permissions for repos and users
  3. Generate the token and copy it
  4. Inside your dotfile profile (.bashrc, .zshrc) add export GITHUB_ACCESS_TOKEN="the token value"
  5. Open a new shell, or run export GITHUB_ACCESS_TOKEN="the token value" in your current shell
  6. Run projectz again

Configuring Projectz

Data Files

Projectz helps you maintain the following data files:

  • package.json
  • bower.json
  • component.json
  • jquery.json

It does this by reading them, combining their data in memory, and then outputting the appropriate fields and over-rides for each file.

If you are making use of multiple meta data files, you may find defining a projectz meta file (projectz.json for JSON, or projectz.cson for CSON) to be useful. The projectz meta file can serve as a central location for the configuration of all the other files. However, if you only require one meta data file, then you can ignore this ability.

Projectz takes notes of these meta data fields:

{
    // Specify your project's human readable name
    "title": "Projectz",

    // Specify your project name
    "name": "projectz",

    // Specify your project's Website URL
    "homepage": "https://github.com/bevry/projectz",

    // Specify your project's demo URL
    // If this is missing, and `homepage` is set, we set it to the `homepage` value
    "demo": "https://github.com/bevry/projectz",

    // Specify your project description
    "description": "Stop wasting time syncing and updating your project's README and Package Files!",

    // Specify your project's SPDX License
    // Uses https://www.npmjs.com/packages/spdx for parsing
    "license": "MIT",

    // Specify your whether the project can run on the client-side in web browsers
    // If this is missing, and the component or bower package files exist, then this becomes `true`
    "browsers": true,

    // Specify your project's author details
    // Can be an array or CSV string
    "author": "2013+ Bevry Pty Ltd <us@bevry.me> (http://bevry.me)",

    // Specify your maintainers
    "maintainers": [
        "Benjamin Lupton (b@lupton.cc) (http://balupton.com)"
    ],

    // Specify your sponsors
    "sponsors": [
        "Benjamin Lupton (b@lupton.cc) (http://balupton.com)"
    ],

    // Specify your contributors
    // This is automatically combined with the contributors from the GitHub Repository API
    "contributors": [
        "Benjamin Lupton (b@lupton.cc) (http://balupton.com)"
    ],

    // Specify your project's repository details
    // If this is missing, and `homepage` is a GitHub URL, this determined automatically
    "repository": {
        "type": "git",
        "url": "https://github.com/bevry/projectz.git"
    },

    // Specify your project's issue tracker
    // If this is missing, and `repository` is a GitHub repository, this determined automatically
    "bugs": {
        "url": "https://github.com/bevry/projectz/issues"
    },

    // Specify your project's badges for use in the readme files
    // Projectz renders badges by sending the `badges` field to the `badges` package.
    // Below is some sample projectz configuration for this field to render our most common badges.
    // Even more badge types and configurations are available than just those included below.
    // Complete details of what is available can be found over at the badges package:
    // https://github.com/bevry/badges
    "badges": {
        "list": [
            "travisci",
            "npmversion",
            "npmdownloads",
            "daviddm",
            "daviddmdev",
            "---",
            "slackin",
            "patreon",
            "gratipay",
            "flattr",
            "paypal",
            "bitcoin",
            "wishlist"
        ],
        "config": {
            "patreonUsername": "bevry",
            "gratipayUsername": "bevry",
            "flattrUsername": "balupton",
            "paypalURL": "https://bevry.me/paypal",
            "bitcoinURL": "https://bevry.me/bitcoin",
            "wishlistURL": "https://bevry.me/wishlist",
            "slackinURL": "https://slack.bevry.me"
        }
    },

  // If you are using the projectz meta file, you can also define this field
  // it allows you to set the configuration for other package systems
  "packages": {
    "bower": {},
    "component": {},
    "jquery": {}
  }
}

Readme Files

Projectz helps you maintain the following readme files:

  • README.md
  • CONTRIBUTING.md
  • LICENSE.md
  • BACKERS.md
  • HISTORY.md

It does this by reading them, and replacing comment tags with the appropriate data.

The following comment tags are supported:

  • <!-- TITLE --> — outputs the package's title field
  • <!-- BADGES --> — outputs the badges you have enabled from your package's badges field
  • <!-- DESCRIPTION --> — outputs the package's description field
  • <!-- INSTALL --> — outputs the package's installation instructions
  • <!-- HISTORY --> — outputs a link to the HISTORY file if it exists, otherwise if it is a Github repository, outputs a link to the releases page
  • <!-- CONTRIBUTE --> — outputs a link to the CONTRIBUTE file if it exists
  • <!-- BACKERS --> — outputs who the backers are for the project, including maintainers, sponsors, funding badges, and contributors
  • <!-- LICENSE --> — outputs a summary of the license information

As well as these comment tags for updating entire files:

  • <!-- LICENSEFILE --> — outputs the complete license information
  • <!-- BACKERSFILE --> — same as <!-- BACKERS --> but made for an individual file instead

As an example, here is a a basic README.md file:

<!-- TITLE -->
<!-- BADGES -->
<!-- DESCRIPTION -->
<!-- INSTALL -->

## Usage
Usage instructions go here

<!-- HISTORY -->
<!-- CONTRIBUTE -->
<!-- BACKERS -->
<!-- LICENSE -->

This README is also, expectedly, built with projectz. View its source.

Discover the release history by heading on over to the HISTORY.md file.

Discover how you can contribute by heading on over to the CONTRIBUTING.md file.

These amazing people are maintaining this project:

No sponsors yet! Will you be the first?

These amazing people have contributed code to this project:

Discover how you can contribute by heading on over to the CONTRIBUTING.md file.

Unless stated otherwise all works are:

and licensed under:

4.2.0

3 months ago

4.1.0

3 months ago

4.1.1

3 months ago

4.0.0

3 months ago

3.2.0

4 months ago

3.1.0

5 months ago

3.4.0

4 months ago

3.0.0

5 months ago

3.3.0

4 months ago

2.23.0

1 year ago

2.22.0

3 years ago

2.21.0

3 years ago

2.20.0

3 years ago

2.19.0

3 years ago

2.18.0

3 years ago

2.17.0

3 years ago

2.16.0

4 years ago

2.15.0

4 years ago

2.14.0

4 years ago

2.13.0

4 years ago

2.12.0

4 years ago

2.11.0

4 years ago

2.10.1

4 years ago

2.10.0

4 years ago

2.9.0

4 years ago

2.7.0

4 years ago

2.6.0

4 years ago

2.5.0

4 years ago

2.4.0

4 years ago

2.3.0

4 years ago

2.2.0

4 years ago

2.1.0

4 years ago

2.0.0

4 years ago

1.19.1

4 years ago

1.18.0

4 years ago

1.19.0

4 years ago

1.17.1

4 years ago

1.17.0

4 years ago

1.16.0

4 years ago

1.15.0

4 years ago

1.14.0

4 years ago

1.13.0

4 years ago

1.12.0

4 years ago

1.11.0

4 years ago

1.10.0

4 years ago

1.9.0

4 years ago

1.8.0

4 years ago

1.7.5

5 years ago

1.7.4

5 years ago

1.7.3

5 years ago

1.7.2

5 years ago

1.7.1

5 years ago

1.7.0

5 years ago

1.6.0

5 years ago

1.5.3

5 years ago

1.5.2

5 years ago

1.5.1

5 years ago

1.5.0

5 years ago

1.4.0

7 years ago

1.3.2

7 years ago

1.3.1

7 years ago

1.3.0

7 years ago

1.2.0

8 years ago

1.1.6

8 years ago

1.1.5

8 years ago

1.1.4

8 years ago

1.1.3

8 years ago

1.1.2

8 years ago

1.1.1

8 years ago

1.1.0

8 years ago

1.0.9

8 years ago

1.0.8

8 years ago

1.0.7

8 years ago

1.0.6

9 years ago

1.0.5

9 years ago

1.0.4

9 years ago

1.0.3

9 years ago

1.0.2

9 years ago

1.0.1

9 years ago

1.0.0

9 years ago

0.5.0

9 years ago

0.4.3

9 years ago

0.4.2

9 years ago

0.4.1

9 years ago

0.4.0

9 years ago

0.3.17

9 years ago

0.3.16

9 years ago

0.3.15

10 years ago

0.3.14

10 years ago

0.3.13

10 years ago

0.3.12

10 years ago

0.3.11

10 years ago

0.3.10

10 years ago

0.3.9

10 years ago

0.3.8

10 years ago

0.3.7

10 years ago

0.3.6

10 years ago

0.3.5

10 years ago

0.3.4

10 years ago

0.3.3

10 years ago

0.3.2

10 years ago

0.3.1

10 years ago

0.3.0

10 years ago

0.2.10

10 years ago

0.2.9

10 years ago

0.2.8

10 years ago

0.2.7

10 years ago

0.2.6

10 years ago

0.2.5

10 years ago

0.2.4

10 years ago

0.2.3

10 years ago

0.2.2

10 years ago

0.2.1

10 years ago

0.2.0

10 years ago

0.1.0

10 years ago

0.0.1

11 years ago