Skip to content

Commit 86cad16

Browse files
committedMar 15, 2020
Renamed all placeholders, and added some new ones
1 parent 3daf349 commit 86cad16

14 files changed

+82
-79
lines changed
 

‎.vscode/launch.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
"type": "node",
3636
"request": "launch",
3737
"name": "Run CLI",
38-
"program": "${workspaceRoot}/bin/project-cli-name.js",
38+
"program": "${workspaceRoot}/bin/my-cli.js",
3939
"args": [],
4040
"env": {
4141
"NODE_ENV": "development"

‎CHANGELOG.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
Change Log
22
====================================================================================================
33
All notable changes will be documented in this file.
4-
Friendly Project Name adheres to [Semantic Versioning](http://semver.org/).
4+
My Project Name adheres to [Semantic Versioning](http://semver.org/).
55

66

7-
[v1.0.0](https://github.com/JS-DevTools/project-package-name/tree/v1.0.0) (XXXX-XX-XX)
7+
[v1.0.0](https://github.com/MyGitHubOrg/my-package-name/tree/v1.0.0) (XXXX-XX-XX)
88
----------------------------------------------------------------------------------------------------
99

1010
Initial release 🎉

‎README.md

+9-6
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ If you **don't** need a CLI, then:
1717
- `bin`
1818
- `src/cli`
1919
- `test/specs/cli.spec.js`
20-
- `test/utils/project-cli-name.js`
20+
- `test/utils/my-cli.js`
2121
- Delete the following fields in `package.json`:
2222
- `bin`
2323
- `files.bin`
@@ -34,11 +34,14 @@ Replace all occurrences of the following placeholders in all files:
3434

3535
|Placeholder |Description
3636
|:----------------------------------|:------------------------------------------------------------
37-
|`project-package-name` |This is the name of the NPM package. It should also match the GitHub repo name. It should be kebab-cased.
38-
|`project-cli-name` |The name of the CLI program for this project, if any.
39-
|`projectExportName` |The name of the library's default export, if any. This should be a valid JavaScript identifier name.
40-
|`Friendly Project Name` |This is the human friendly name of the project that is used in the ReadMe, descriptions, and docs pages
41-
|`This is the project description` |A short, human friendly description of the project that is used in the ReadMe and package.json
37+
|`MyGitHubOrg` |This is the name of the GitHub org for this repository, such as "JS-DevTools".
38+
|`MyTwitterAccount` |This is the name of the Twitter account associated with this project, such as "JSDevTools".
39+
|`@my-npm-scope` |This is the name of the NPM scope that the package will be published to, such as "@jsdevtools".
40+
|`my-package-name` |This is the name of the NPM package. It should also match the GitHub repo name. It should be kebab-cased.
41+
|`my-cli` |The name of the CLI program for this project, if any.
42+
|`myLibrary` |The name of the library's default export, if any. This should be a valid JavaScript identifier name.
43+
|`My Project Name` |This is the human friendly name of the project that is used in the ReadMe, descriptions, and docs pages
44+
|`The description of my library` |A short, human friendly description of the project that is used in the ReadMe and package.json
4245

4346

4447

‎README_md

+14-14
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
1-
Friendly Project Name
1+
My Project Name
22
==============================================
3-
### This is the project description
3+
### The description of my library
44

5-
[![Cross-Platform Compatibility](https://jstools.dev/img/badges/os-badges.svg)](https://github.com/JS-DevTools/project-package-name/blob/master/.github/workflows/CI-CD.yaml)
6-
[![Build Status](https://github.com/JS-DevTools/project-package-name/workflows/CI-CD/badge.svg)](https://github.com/JS-DevTools/project-package-name/blob/master/.github/workflows/CI-CD.yaml)
5+
[![Cross-Platform Compatibility](https://jstools.dev/img/badges/os-badges.svg)](https://github.com/MyGitHubOrg/my-package-name/blob/master/.github/workflows/CI-CD.yaml)
6+
[![Build Status](https://github.com/MyGitHubOrg/my-package-name/workflows/CI-CD/badge.svg)](https://github.com/MyGitHubOrg/my-package-name/blob/master/.github/workflows/CI-CD.yaml)
77

8-
[![Coverage Status](https://coveralls.io/repos/github/JS-DevTools/project-package-name/badge.svg?branch=master)](https://coveralls.io/github/JS-DevTools/project-package-name)
9-
[![Dependencies](https://david-dm.org/JS-DevTools/project-package-name.svg)](https://david-dm.org/JS-DevTools/project-package-name)
8+
[![Coverage Status](https://coveralls.io/repos/github/MyGitHubOrg/my-package-name/badge.svg?branch=master)](https://coveralls.io/github/MyGitHubOrg/my-package-name)
9+
[![Dependencies](https://david-dm.org/MyGitHubOrg/my-package-name.svg)](https://david-dm.org/MyGitHubOrg/my-package-name)
1010

11-
[![npm](https://img.shields.io/npm/v/@jsdevtools/project-package-name.svg)](https://www.npmjs.com/package/@jsdevtools/project-package-name)
12-
[![License](https://img.shields.io/npm/l/@jsdevtools/project-package-name.svg)](LICENSE)
11+
[![npm](https://img.shields.io/npm/v/@my-npm-scope/my-package-name.svg)](https://www.npmjs.com/package/@my-npm-scope/my-package-name)
12+
[![License](https://img.shields.io/npm/l/@my-npm-scope/my-package-name.svg)](LICENSE)
1313

1414

1515

@@ -25,7 +25,7 @@ Example
2525
--------------------------
2626

2727
```javascript
28-
import projectExportName from "@jsdevtools/project-package-name";
28+
import myLibrary from "@my-npm-scope/my-package-name";
2929

3030
// TODO: Add a usage example here
3131
```
@@ -34,10 +34,10 @@ import projectExportName from "@jsdevtools/project-package-name";
3434

3535
Installation
3636
--------------------------
37-
You can install Friendly Project Name via [npm](https://docs.npmjs.com/about-npm/).
37+
You can install My Project Name via [npm](https://docs.npmjs.com/about-npm/).
3838

3939
```bash
40-
npm install @jsdevtools/project-package-name
40+
npm install @my-npm-scope/my-package-name
4141
```
4242

4343

@@ -50,13 +50,13 @@ TODO: Document the library's API and CLI usage
5050

5151
Contributing
5252
--------------------------
53-
Contributions, enhancements, and bug-fixes are welcome! [File an issue](https://github.com/JS-DevTools/project-package-name/issues) on GitHub and [submit a pull request](https://github.com/JS-DevTools/project-package-name/pulls).
53+
Contributions, enhancements, and bug-fixes are welcome! [File an issue](https://github.com/MyGitHubOrg/my-package-name/issues) on GitHub and [submit a pull request](https://github.com/MyGitHubOrg/my-package-name/pulls).
5454

5555
#### Building
5656
To build the project locally on your computer:
5757

5858
1. __Clone this repo__<br>
59-
`git clone https://github.com/JS-DevTools/project-package-name.git`
59+
`git clone https://github.com/MyGitHubOrg/my-package-name.git`
6060

6161
2. __Install dependencies__<br>
6262
`npm install`
@@ -71,7 +71,7 @@ To build the project locally on your computer:
7171

7272
License
7373
--------------------------
74-
Friendly Project Name is 100% free and open-source, under the [MIT license](LICENSE). Use it however you want.
74+
My Project Name is 100% free and open-source, under the [MIT license](LICENSE). Use it however you want.
7575

7676

7777

‎_config.yml

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
1-
remote_theme: JS-DevTools/gh-pages-theme
1+
remote_theme: MyGitHubOrg/gh-pages-theme
22

3-
title: Friendly Project Name
3+
title: My Project Name
44
logo: https://jstools.dev/img/logos/logo.png
55

66
author:
7-
twitter: JSDevTools
7+
twitter: MyTwitterAccount
88

99
google_analytics: UA-68102273-3
1010

1111
twitter:
12-
username: JSDevTools
12+
username: MyTwitterAccount
1313
card: summary
1414

1515
defaults:
File renamed without changes.

‎package.json

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,22 @@
11
{
2-
"name": "@jsdevtools/project-package-name",
2+
"name": "@my-npm-scope/my-package-name",
33
"version": "0.0.1",
4-
"description": "This is the project description",
4+
"description": "The description of my library",
55
"keywords": [],
66
"author": {
77
"name": "James Messinger",
88
"url": "https://jamesmessinger.com"
99
},
1010
"license": "MIT",
11-
"homepage": "https://jstools.dev/project-package-name",
11+
"homepage": "https://jstools.dev/my-package-name",
1212
"repository": {
1313
"type": "git",
14-
"url": "https://github.com/JS-DevTools/project-package-name.git"
14+
"url": "https://github.com/MyGitHubOrg/my-package-name.git"
1515
},
1616
"main": "lib/index.js",
1717
"types": "lib/index.d.ts",
1818
"bin": {
19-
"project-cli-name": "bin/project-cli-name.js"
19+
"my-cli": "bin/my-cli.js"
2020
},
2121
"files": [
2222
"bin",

‎src/cli/index.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
// tslint:disable: no-console
2-
import { projectExportName } from "..";
2+
import { myLibrary } from "..";
33
import { ExitCode } from "./exit-code";
44
import { helpText } from "./help";
55
import { manifest } from "./manifest";
@@ -30,7 +30,7 @@ export function main(args: string[]): void {
3030
process.exit(ExitCode.Success);
3131
}
3232
else {
33-
let result = projectExportName(options);
33+
let result = myLibrary(options);
3434

3535
if (!quiet) {
3636
console.log(result);

‎src/index.ts

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
1-
import { projectExportName } from "./project-package-name";
1+
import { myLibrary } from "./my-package-name";
22

33
export { Options } from "./settings";
4-
export { projectExportName };
4+
export { myLibrary };
55

6-
// Export `projectExportName` as the default export
6+
// Export `myLibrary` as the default export
77
// tslint:disable: no-default-export
8-
export default projectExportName;
8+
export default myLibrary;
99

1010
// CommonJS default export hack
1111
if (typeof module === "object" && typeof module.exports === "object") {

‎src/project-package-name.ts ‎src/my-package-name.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
import { Options, Settings } from "./settings";
22

33
/**
4-
* This is the project description
4+
* The description of my library
55
*
66
* @returns - Options
77
*/
8-
export function projectExportName(options?: Options): string {
8+
export function myLibrary(options?: Options): string {
99
let settings = new Settings(options);
1010

1111
if (settings.greeting === "Goodbye") {

‎test/specs/api.spec.js

+7-7
Original file line numberDiff line numberDiff line change
@@ -1,33 +1,33 @@
11
"use strict";
22

3-
const projectExportName = require("../../");
3+
const myLibrary = require("../../");
44
const { expect } = require("chai");
55

6-
describe("projectExportName() API", () => {
6+
describe("myLibrary() API", () => {
77

88
it("should work without any arguments", () => {
9-
let result = projectExportName();
9+
let result = myLibrary();
1010
expect(result).to.equal("Hello, world.");
1111
});
1212

1313
it("should accept a custom greeting", () => {
14-
let result = projectExportName({ greeting: "Hi there" });
14+
let result = myLibrary({ greeting: "Hi there" });
1515
expect(result).to.equal("Hi there, world.");
1616
});
1717

1818
it("should accept a custom subject", () => {
19-
let result = projectExportName({ subject: "Michael" });
19+
let result = myLibrary({ subject: "Michael" });
2020
expect(result).to.equal("Hello, Michael.");
2121
});
2222

2323
it("should accept a custom greeting and subject", () => {
24-
let result = projectExportName({ greeting: "Yo", subject: "man" });
24+
let result = myLibrary({ greeting: "Yo", subject: "man" });
2525
expect(result).to.equal("Yo, man.");
2626
});
2727

2828
it('should not allow a greeting of "goodbye"', () => {
2929
function sayGoodbye () {
30-
projectExportName({ greeting: "Goodbye" });
30+
myLibrary({ greeting: "Goodbye" });
3131
}
3232

3333
expect(sayGoodbye).to.throw("Cannot say goodbye");

0 commit comments

Comments
 (0)
Failed to load comments.