Skip to content

Commit

Permalink
Initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
Stephen Hanson committed May 3, 2023
0 parents commit 0058a47
Show file tree
Hide file tree
Showing 12 changed files with 511 additions and 0 deletions.
8 changes: 8 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
node_modules/
package-lock.json
yarn-error.log*
yarn-debug.log*
npm-debug.log
.idea/*
.vscode/*
.DS_Store
15 changes: 15 additions & 0 deletions CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# Lines starting with '#' are comments.
# Each line is a file pattern followed by one or more owners.

# More details are here: https://help.github.com/articles/about-codeowners/

# The '*' pattern is global owners.

# Order is important. The last matching pattern has the most precedence.
# The folders are ordered as follows:

# In each subsection folders are ordered first by depth, then alphabetically.
# This should make it easy to add new rules without breaking existing ones.

# Global rule:
* @stevehanson
6 changes: 6 additions & 0 deletions CODE_OF_CONDUCT.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Code of conduct

By participating in this project, you agree to abide by the
[thoughtbot code of conduct][1].

[1]: https://thoughtbot.com/open-source-code-of-conduct
41 changes: 41 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
# Contributing

We love contributions from everyone. By participating in this project, you agree
to abide by the [code of conduct](./CODE_OF_CONDUCT.md).

We expect everyone to follow the code of conduct anywhere in thoughtbot's
project codebases, issue trackers, chatrooms, and mailing lists.

## Contributing Code

Fork the repo.

Install dependencies:

```bash
yarn install
```

Make sure the tests pass:

```bash
yarn test
```

Make your change, with new passing tests. Before committing your changes, run the code formatter:

```bash
yarn pretty
```

Follow the [style guide][style].

[style]: https://github.com/thoughtbot/guides

Push to your fork. Write a [good commit message][commit]. Submit a pull request.

[commit]: http://tbaggery.com/2008/04/19/a-note-about-git-commit-messages.html

Others will give constructive feedback. This is a time for discussion and
improvements, and making the necessary changes will be required before we can
merge the contribution.
19 changes: 19 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
Copyright (c) 2023 Stephen Hanson and thoughtbot, inc.

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
43 changes: 43 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
# Suspenders CLI

Perform project setup and redundant tasks without your pants falling down!

This project is still in very early stages. Track this project [in Trello](https://trello.com/b/AGqz2thm/react-native-cli) or in Slack (`#proj-react-native-cli`).

## Usage

Ensure you have a recent version of Node.js installed, then install dependencies:

```
yarn install
```

Only the scaffolding is in place right now. Some example commands:

```
> yarn suspenders react-native eslint
> yarn suspenders react-native prettier
```

## Contributing

See the [CONTRIBUTING](./CONTRIBUTING.md) document. Thank you, [contributors](https://github.com/thoughtbot/fishery/graphs/contributors)!

## License

Suspenders CLI is Copyright © 2023 Stephen Hanson and thoughtbot. It is free
software, and may be redistributed under the terms specified in the
[LICENSE](/LICENSE) file.

### About thoughtbot

<img src="https://thoughtbot.com/thoughtbot-logo-for-readmes.svg" width="375" />

Suspenders CLI is maintained and funded by thoughtbot, inc.
The names and logos for thoughtbot are trademarks of thoughtbot, inc.

We love open source software! See [our other projects][community] or
[hire us][hire] to design, develop, and grow your product.

[community]: https://thoughtbot.com/community?utm_source=github
[hire]: https://thoughtbot.com/hire-us?utm_source=github
16 changes: 16 additions & 0 deletions index.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
import { Option, program } from "commander";

program
.name("suspenders")
.description(
"Perform project setup and redundant tasks without your pants falling down!"
)
.command(
"react-native <subcommand> [options]",
"Perform a React Native task",
{ executableFile: "react-native/react-native.js" }
)
.alias("rn")
.alias("expo")
.showHelpAfterError()
.parse();
18 changes: 18 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{
"name": "suspenders-cli",
"version": "1.0.0",
"description": "Monorepo for project bootstrapping CLIs",
"main": "index.js",
"type": "module",
"scripts": {
"suspenders": "node ./index.js",
"test": "echo \"Error: no test specified\" && exit 1"
},
"author": "Stephen Hanson",
"license": "MIT",
"dependencies": {
"commander": "^10.0.1",
"inquirer": "^9.2.0"
},
"devDependencies": {}
}
1 change: 1 addition & 0 deletions react-native/eslint.js
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
console.log('ESLint!')
1 change: 1 addition & 0 deletions react-native/react-native-prettier.js
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
console.log("Prettier!");
10 changes: 10 additions & 0 deletions react-native/react-native.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
import { program } from "commander";

console.log("React Native 🎉");

program
.description('Perform React Native and Expo setup and redundant tasks without your pants falling down!')
.command("eslint", "Configure ESLint", { executableFile: "eslint.js" })
.command("prettier", "Configure Prettier", { executableFile: "prettier.js" });

program.parse();
Loading

0 comments on commit 0058a47

Please sign in to comment.