This repository contains bash files to quickly skip all install processes by running a single command
- Npm and Node.js must be installed
- Should be run on a linux terminal
- Configured on bash terminal
- Have Git installed (optional)
- Have vs-code installed and added to path (optional)
The tailwind.sh file runs all the necessary tailwind commands so you can immediately start your project
- Create a new project folder (
mkdir example-project
) - Enter the newly created folder (
cd example-project
) - Copy the tailwind.sh into the new folder
- Run
bash tailwind.sh
in that folder
- Installs tailwind css
- Installs prettier for tailwind
- Creates all necessary html, css and js files
- Creates "build" and "watch" commands in package.json file
- Links index.html to the created css and js files
- Links tailwind.config file to watch all html files in that folder
- If git is installed, then it initializes a new repository
- If VsCode is installed then it opens the folder
The react-vite-tailwind.sh
file runs all commands to immediately start a react application with tailwind automatically configured
- Copy the
react-vite-tailwind.sh
into a folder on your machine (I would call this theparent
) - Create a new project folder inside the parent folder (
mkdir new-project
) - Enter the newly created folder (
cd new-project
) - Run
bash ../react-vite-tailwind.sh
in that folder. The default configuration is Javascript but if you want to use typescript then add thets
param to the commandbash ../react-vite-tailwind.sh ts
- Creates a React application using vite (javascript or typescript template as specified)
- Install TailwindCSS and the necessary config packages
- Install prettier plugin for tailwind
- Configures both tailwind and prettier
- Replaces the default
App
source code withhello world
- If git is installed, then it initializes a new repository
- If VsCode is installed then it opens the folder
The next-tailwind.sh initilizes a NextJs project with tailwind installed. The program installs NextJs
version 13.1.6
.
By default, this project is made to be Non-interactive so you won't see any of these prompts
This would be updated depending on the changes made in future NextJs version
- Copy the
next-tailwind.sh
into a folder on your machine (I would call this theparent
) - Create a new project folder inside the
parent
folder (mkdir new-project
) - Enter the newly created folder (
cd new-project
) - Run
bash ../next-tailwind.sh [options]
Options:
Initialize as a typescript project ( default: javascript )
ts
Initialize with eslint config ( default: no eslint )
lint
Initialize as a `app/` directory project ( default: without app directory )
app
Initialize inside a `src/` directory( default: without src folder )
src
Explicitly tell the CLI to bootstrap the app using pnpm ( default: uses npm )
pnpm
By default the import alias is "@/*" and this behaviour cannot be changed
Note: Any missing option would make use of the default. All and any parameter could be eliminated and also there's no specified ordering for them
bash ../next-tailwind.sh app ts lint
bash ../next-tailwind.sh src pnpm ts
bash ../next-tailwind.sh
- Creates a NextJs version 13.1.6 application using the specified configurations
- Install TailwindCSS and the necessary config packages
- Install prettier plugin for tailwind
- Configures both tailwind and prettier
- Replaces the default
App
code withhello world
- If git is installed, then it initializes a new repository
- If VsCode is installed then it opens the folder
One good idea is to copy these files into the root (~
in bash) of the machine. This way you don't have to worry about any parent or child and would just run
bash ~/<script-name>
in any folder and it would work as expected. The scripts would be accessible globally