/theturtle-folder

This is a simple way to create folders and optimize repetitive tasks

Primary LanguageJavaScriptMIT LicenseMIT

TypeScript NodeJs Prompts

LICENSE

🛠️ Requirements

  • Node: (20.8.0)

🚀 Execute

npx @theturtle/folder

⚙️ Installation

1. Clone the repository

git clone https://github.com/r89shi/theturtle-folder.git

2. Install the dependencies

npm install

OR

yarn install

OR

pnpm install

📦 3. Build

npm run build

OR

yarn build

OR

pnpm build

🐇 4. Run

npm start

OR

yarn start

OR

pnpm start

🐞 Run developer mode

npm run dev

OR

yarn dev

OR

pnpm dev

📂 Create new folder structure

Create a JSON file into the database folder: src/database/fileName.json

Open the JSON file and insert the code:

{
  "root": []
}

root is required for any JSON file. To create a new folder:

{
  "root": [
    {
      "name": "First folder name",
      "sub": []
    }
  ]
}

name : Folder name.

sub : Sub directories for this folder.

To create a sub folders, insert into sub the same structure.

Example:

{
  "root": [
    {
      "name": "First folder name",
      "sub": [
        {
          "name": "Sub folder name",
          "sub": []
        },
        {
          "name": "Another sub folder name",
          "sub": []
        }
      ]
    }
  ]
}