sudo npm install -g speed-setup-cli
SPEED is a powerful Command Line Interface (CLI) tool designed to streamline the setup of TypeScript and Node.js development environments. With SPEED, configuring your backend project becomes effortless—install essential dependencies and generate necessary configuration files with just a few commands.
- One-Click Setup: Initialize a TypeScript and Node.js project with a single command.
- Automated Dependency Installation: Installs essential packages like Express, dotenv, Jest, ESLint, and Prettier.
- Configuration File Generation: Automatically generates configuration files (`tsconfig.json`, `.eslintrc.js`, `.prettierrc`, `.env`).
- Modular Installation Options: Choose to install specific dependencies or all at once.
- Flexible Module System: Select between CommonJS and ES Modules.
- Interactive CLI: User-friendly prompts guide you through the setup process.
- Customizable Project Structure: Define your project name, source folder, and entry file.
Before using SPEED, ensure you have the following installed on your machine:
- Node.js: Version 12 or higher. Download Node.js
- npm: Comes bundled with Node.js. Ensure it's updated to the latest version:
npm install -g npm
Install SPEED globally using npm to access it from anywhere in your terminal:
npm install -g speed-setup-cli
Note: You might need administrator privileges to install global packages. Use `sudo` on Unix-based systems if necessary:
sudo npm install -g speed-setup-cli
After installation, initiate the setup process by running:
speed
When you execute `speed`, you'll be guided through a series of prompts to customize your project setup:
- Project Name: Enter the desired name for your project. A directory with this name will be created.
- Source Folder Name: Specify the name of the source folder (default is `src`).
- Entry File: Define the entry file for your application (default is `server.ts`).
-
Feature Installation:
-
Y
: Install all essential features (Express, dotenv, Jest, ESLint, Prettier). -
N
: Skip the installation of additional features. -
C
: Choose specific features to install.
-
-
Module System:
-
1
: CommonJS -
2
: ES Modules
-
$ speed
Hello Developer! 😃👋 Let's configure the backend of your amazing project. 🚀
=======================================================================
⚠️ Some operations may require administrator rights. Please ensure you're running this program with the necessary permissions.
The project Name: **my_project**
Source folder name (default: src): **src**
Entry file (default: my_project/src/server.ts): **server.ts**
Want to add some cool 😎 features (Y for yes, N for no, C for choose): **Y**
Enter "1" for CommonJS and "2" for ES Modules: **2**
🔧 Installing Express and its type definitions...
✅ Express installed successfully!
🔧 Installing Dotenv and its type definitions...
✅ Dotenv installed successfully!
🔧 Installing Jest and its type definitions...
✅ Jest installed successfully!
🔧 Installing ESLint and its type definitions...
✅ ESLint installed successfully!
🔧 Installing Prettier and its type definitions...
✅ Prettier installed successfully!
========================================
✅ **Setup Summary:**
- **Project Name**: my_project
- **Source Folder**: src
- **Entry File**: server.ts
- **Module System**: ES Modules
- **Installed Features**:
- Express
- Dotenv
- Jest
- ESLint
- Prettier
========================================
**Next Steps:**
cd my_project npm run build npm start
Navigate to [http://localhost:3000](http://localhost:3000)
🎉 **All done!** You're ready to start building your project.
❤️ Thanks for using Open Node Services! Visit our site: [https://opennode.tech](https://opennode.tech)
After running SPEED, your project directory will have the following structure:
my_project/
├── src/
│ └── server.ts
├── dist/
├── node_modules/
├── .env
├── .eslintrc.js
├── .prettierrc
├── package.json
├── tsconfig.json
├── .gitignore
└── README.md
- src/: Contains the source TypeScript files.
- dist/: Compiled JavaScript files after building the project.
- .env: Environment variables.
- .eslintrc.js: ESLint configuration.
- .prettierrc: Prettier configuration.
- package.json: Project metadata and scripts.
- tsconfig.json: TypeScript compiler options.
- .gitignore: Specifies files and directories to be ignored by Git.
- README.md: Project documentation.
SPEED sets up several npm scripts to streamline your development workflow:
- build: Compiles TypeScript into JavaScript.
npm run build
- start: Runs the compiled JavaScript code.
- dev: Starts development mode with nodemon and ts-node for automatic reloading.
- test: Runs tests using Jest (if installed).
Contributions are welcome! If you find a bug or have a feature request, please open an issue on the GitHub repository.
- Fork the Repository
- Create a New Branch
- Commit Your Changes
- Push to the Branch
- Open a Pull Request
This project is licensed under the MIT License.
Ensure you have a `LICENSE` file in your repository containing the MIT License text.
DEVOUE-LI-TCHIBENI Dona-Dieu-Talliane
User: donadev56
Made with ♥ by Open Node Services
- Clone the Repository
- Navigate to the Directory
- Install Dependencies
- Run the CLI
For any questions or support, feel free to reach out via our GitHub Issues or visit our website.
© 2024 Open Node Services. All rights reserved.