git0 0.2.3 → 0.2.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (53) hide show
  1. package/docs/404.html +27 -0
  2. package/docs/CNAME +1 -0
  3. package/docs/Footer/index.html +27 -0
  4. package/docs/assets/css/styles.3dd00f8d.css +1 -0
  5. package/docs/assets/js/17896441.79ceefeb.js +1 -0
  6. package/docs/assets/js/1df93b7f.dfdf0ef3.js +2 -0
  7. package/docs/assets/js/1df93b7f.dfdf0ef3.js.LICENSE.txt +6 -0
  8. package/docs/assets/js/22dd74f7.5e857962.js +1 -0
  9. package/docs/assets/js/237.daf7efdf.js +1 -0
  10. package/docs/assets/js/278.1628756c.js +1 -0
  11. package/docs/assets/js/4a829dc8.728a4445.js +1 -0
  12. package/docs/assets/js/577.78325c02.js +1 -0
  13. package/docs/assets/js/591.2156b33d.js +2 -0
  14. package/docs/assets/js/591.2156b33d.js.LICENSE.txt +61 -0
  15. package/docs/assets/js/5e95c892.bd6c1093.js +1 -0
  16. package/docs/assets/js/a7456010.3054873b.js +1 -0
  17. package/docs/assets/js/a7bd4aaa.87229397.js +1 -0
  18. package/docs/assets/js/a94703ab.6d39a596.js +1 -0
  19. package/docs/assets/js/aba21aa0.dfebd789.js +1 -0
  20. package/docs/assets/js/ac46717f.32345167.js +2 -0
  21. package/docs/assets/js/ac46717f.32345167.js.LICENSE.txt +6 -0
  22. package/docs/assets/js/c3a618e1.50a89e4d.js +1 -0
  23. package/docs/assets/js/d140250a.62af53aa.js +1 -0
  24. package/docs/assets/js/main.c71c09a5.js +2 -0
  25. package/docs/assets/js/main.c71c09a5.js.LICENSE.txt +68 -0
  26. package/docs/assets/js/runtime~main.ef55418f.js +1 -0
  27. package/docs/functions/globals/index.html +57 -0
  28. package/docs/functions/index.html +74 -0
  29. package/docs/index.html +27 -0
  30. package/docs/lunr-index-1749601667754.json +1 -0
  31. package/docs/lunr-index.json +1 -0
  32. package/docs/search-doc-1749601667754.json +1 -0
  33. package/docs/search-doc.json +1 -0
  34. package/docs/sitemap.xml +1 -0
  35. package/docs-config/config/customize-docs.js +29 -0
  36. package/docs-config/config/docs-theme.css +358 -0
  37. package/docs-config/config/openapi.mustache +39 -0
  38. package/docs-config/config/sidebars.ts +21 -0
  39. package/docs-config/config/typedoc.json +40 -0
  40. package/docs-config/docusaurus.config.ts +350 -0
  41. package/docs-config/package.json +40 -0
  42. package/docs-config/src/functions/globals.md +153 -0
  43. package/docs-config/src/functions/index.md +114 -0
  44. package/docs-config/src/functions/typedoc-sidebar.cjs +6 -0
  45. package/docs-config/src/index.md +127 -0
  46. package/docs-config/src/pages/Footer.tsx +67 -0
  47. package/docs-config/src/pages/index.tsx +424 -0
  48. package/docs-config/static/CNAME +1 -0
  49. package/docs-config/tailwind.config.js +13 -0
  50. package/docs-config/tsconfig.json +27 -0
  51. package/git0.js +6 -6
  52. package/package.json +15 -15
  53. package/readme.md +37 -38
package/git0.js CHANGED
@@ -19,7 +19,6 @@ const githubHelpUrl = 'https://github.com/settings/personal-access-tokens/new'
19
19
  grab('', {
20
20
  setDefaults: true,
21
21
  debug: false,
22
- timeout: 5000,
23
22
  onError: (error) => {
24
23
  if (error.includes('403')) {
25
24
  log(chalk.red('Rate limit exceeded. Please set env var GITHUB_TOKEN. Help:\n' + githubHelpUrl));
@@ -332,7 +331,8 @@ function getIdeCommand() {
332
331
  { name: 'Windsurf', cmd: 'windsurf' },
333
332
  { name: 'VSCode', cmd: 'code' },
334
333
  { name: 'Code Server', cmd: 'code-server' },
335
- { name: 'Neovim', cmd: 'nvim' }
334
+ { name: 'Neovim', cmd: 'nvim' },
335
+ { name: 'Webstorm', cmd: 'webstorm' }
336
336
  ];
337
337
 
338
338
  for (const ide of ides) {
@@ -397,6 +397,7 @@ export function openInIDE(targetDir) {
397
397
  export async function installDependencies(targetDir) {
398
398
  process.chdir(targetDir);
399
399
 
400
+
400
401
  // Project type detection
401
402
  const detectors = {
402
403
  nodejs: () => fs.existsSync('package.json'),
@@ -464,8 +465,6 @@ function runCommand(cmd) {
464
465
  }
465
466
 
466
467
  export async function searchRepositories(query) {
467
- printLogo()
468
-
469
468
  try {
470
469
  const response = await grab(GITHUB_API, {
471
470
  q: `${query} in:name`,
@@ -541,9 +540,9 @@ export async function downloadRepo(repo) {
541
540
  response = await grab(url.replace("/master", "/main"), params);
542
541
 
543
542
 
544
- // setTimeout(() => {
543
+ setTimeout(() => {
545
544
  openInIDE(extractPath);
546
- // }, 1);
545
+ }, 1000);
547
546
  installDependencies(extractPath);
548
547
  } catch (error) {
549
548
  console.error(chalk.red('Download failed:'), error.message);
@@ -563,6 +562,7 @@ function getAvailableDirectoryName(basePath) {
563
562
  }
564
563
 
565
564
  async function main() {
565
+ printLogo()
566
566
  const args = process.argv.slice(2);
567
567
  if (!args.length) {
568
568
  log(chalk.yellow('Usage: gg <search-query>'));
package/package.json CHANGED
@@ -1,14 +1,8 @@
1
1
  {
2
2
  "name": "git0",
3
- "version": "0.2.3",
4
- "description": "A CLI manager for downloading GitHub repos.",
3
+ "description": "CLI tool to search GitHub repositories, download source & releases for your system, and instantly set up, then install dependencies and open code editor.",
4
+ "version": "0.2.5",
5
5
  "author": "vtempest",
6
- "license": "MIT",
7
- "keywords": [
8
- "github",
9
- "cli",
10
- "download"
11
- ],
12
6
  "dependencies": {
13
7
  "axios": "^1.9.0",
14
8
  "chalk": "^5.4.1",
@@ -18,14 +12,20 @@
18
12
  "streamable": "^0.6.0",
19
13
  "tar": "^7.4.3"
20
14
  },
21
- "scripts": {
22
- "demo": "bun gg.js react template",
23
- "publish:npm": "npm version patch && npm publish --access public"
24
- },
25
- "type": "module",
26
- "main": "./git0.js",
27
15
  "bin": {
28
16
  "gg": "./git0.js",
29
17
  "git0": "./git0.js"
30
- }
18
+ },
19
+ "keywords": [
20
+ "github",
21
+ "cli",
22
+ "download"
23
+ ],
24
+ "license": "MIT",
25
+ "scripts": {
26
+ "docs": "cd docs-config && bun run build:docs",
27
+ "demo": "bun git0.js react template",
28
+ "publish:npm": "npm version patch && npm publish --access public"
29
+ },
30
+ "type": "module"
31
31
  }
package/readme.md CHANGED
@@ -6,30 +6,39 @@
6
6
  <img src="https://img.shields.io/discord/1110227955554209923.svg?label=Chat&logo=Discord&colorB=7289da&style=flat"
7
7
  alt="Join Discord" />
8
8
  </a>
9
- <a href="https://github.com/vtempest/gg/discussions">
10
- <img alt="GitHub Stars" src="https://img.shields.io/github/stars/vtempest/gg" /></a>
11
- <a href="https://github.com/vtempest/gg/discussions">
9
+ <a href="https://github.com/vtempest/git0/discussions">
10
+ <img alt="GitHub Stars" src="https://img.shields.io/github/stars/vtempest/git0" /></a>
11
+ <a href="https://github.com/vtempest/git0/discussions">
12
12
  <img alt="GitHub Discussions"
13
- src="https://img.shields.io/github/discussions/vtempest/gg" />
13
+ src="https://img.shields.io/github/discussions/vtempest/git0" />
14
14
  </a>
15
- <a href="https://github.com/vtempest/gg/pulse" alt="Activity">
16
- <img src="https://img.shields.io/github/commit-activity/m/vtempest/gg" />
15
+ <a href="https://github.com/vtempest/git0/pulse" alt="Activity">
16
+ <img src="https://img.shields.io/github/commit-activity/m/vtempest/git0" />
17
17
  </a>
18
- <img src="https://img.shields.io/github/last-commit/vtempest/gg.svg?style=flat-square" alt="GitHub last commit" />
18
+ <img src="https://img.shields.io/github/last-commit/vtempest/git0.svg?style=flat-square" alt="GitHub last commit" />
19
19
  </p>
20
20
  <p align="center">
21
21
  <img src="https://img.shields.io/badge/PRs-welcome-brightgreen.svg?style=flat-square"
22
22
  alt="PRs Welcome" />
23
- <a href="https://codespaces.new/vtempest/gg">
23
+ <a href="https://codespaces.new/vtempest/git0">
24
24
  <img src="https://github.com/codespaces/badge.svg" width="150" height="20" />
25
25
  </a>
26
26
  </p>
27
27
 
28
28
 
29
- # Git0: Git Package Manager with Zero Steps
29
+ # Git0: Download Git Repo on Step Zero
30
+ CLI tool to search GitHub repositories, download source & releases for your system, and instantly set up, then install dependencies and open code editor.
30
31
 
31
- CLI tool to search, download source & releases for your system, and
32
- instantly set up GitHub repositories with automatic dependency installation and code editor opening.
32
+
33
+ ## 🚀 Installation
34
+
35
+ ```bash
36
+ npm install -g git0
37
+ ```
38
+
39
+ ```bash
40
+ bun install -g git0
41
+ ```
33
42
 
34
43
  ![livepreview](https://i.imgur.com/Io3ukRC.gif)
35
44
  ![preview](https://i.imgur.com/K22NiBq.png)
@@ -38,7 +47,7 @@ instantly set up GitHub repositories with automatic dependency installation and
38
47
  ## ✨ Features
39
48
 
40
49
  - **Search GitHub repositories** by name with fuzzy matching
41
- - **Download repositories** directly from GitHub URLs or owner/repo shortcuts
50
+ - **Download repositories** directly from GitHub URLs or owner/repo shortcuts. Skip the manual git clone, cd, install dance
42
51
  - **Get Releases** instantly download latest release for your system or all systems
43
52
  - **Automatic dependency detection** and installation for multiple project types
44
53
  - **Smart IDE integration** - automatically opens projects in your preferred editor
@@ -48,30 +57,25 @@ instantly set up GitHub repositories with automatic dependency installation and
48
57
 
49
58
  ## 🎯 Usage
50
59
 
51
-
52
- ### Search and Download
53
60
  ```bash
54
- # install in bun or node
55
- npm i -g git0
56
- bun i -g git0
57
-
58
61
  # Search for repositories by name
59
62
  gg react starter
60
63
 
61
64
  # Direct download from GitHub URL
65
+ ## gg and git0 both work
62
66
  gg https://github.com/facebook/react
63
67
 
64
68
  # Download using owner/repo shorthand
65
- ## gg and git0 both work
66
- git0 facebook/react
69
+ git0 react starter
67
70
 
68
- ## Use without installing
69
- npx git0 react starter
71
+ ## Use git0 without installing, (only node needed)
72
+ # (copy into your project's readme for quick setup)
73
+ npx git0 facebook/react
70
74
  ```
71
75
 
72
76
  ### Supported Project Types
73
77
 
74
- `git0` automatically detects and sets up the following project types:
78
+ git0 automatically detects and sets up the following project types:
75
79
 
76
80
  | Project Type | Detection | Installation |
77
81
  |-------------|-----------|-------------|
@@ -83,7 +87,7 @@ npx git0 react starter
83
87
 
84
88
  ### Supported IDEs
85
89
 
86
- `git0` automatically detects and opens projects in your preferred IDE:
90
+ git0 automatically detects and opens projects in your preferred IDE:
87
91
 
88
92
  - **Cursor** (`cursor`)
89
93
  - **Windsurf** (`windsurf`)
@@ -93,15 +97,7 @@ npx git0 react starter
93
97
 
94
98
  ## 🔧 Configuration
95
99
 
96
- ### GitHub Token (Optional)
97
100
 
98
- For higher API rate limits, set [your GitHub token](https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/managing-your-personal-access-tokens#creating-a-fine-grained-personal-access-token):
99
-
100
- ```bash
101
- export GITHUB_TOKEN=your_github_token_here
102
- ```
103
-
104
- Without a token, you're limited to 60 requests per hour. With a token, you get 5,000 requests per hour.
105
101
 
106
102
  ### What Happens After Download
107
103
 
@@ -111,11 +107,14 @@ Without a token, you're limited to 60 requests per hour. With a token, you get 5
111
107
  4. **IDE is launched** automatically (if available)
112
108
  5. **Development server starts** (for Node.js projects)
113
109
 
114
- If a directory with the same name exists, `git0` automatically appends a number (e.g., `react-2`, `react-3`).
110
+ If a directory with the same name exists, git0 automatically appends a number (e.g., `react-2`, `react-3`).
111
+
112
+ ### GitHub Token (Optional)
113
+
114
+ For higher API rate limits, set [your GitHub token](https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/managing-your-personal-access-tokens#creating-a-fine-grained-personal-access-token):
115
115
 
116
- ## 🎉 Why GG?
116
+ ```bash
117
+ export GITHUB_TOKEN=your_github_token_here
118
+ ```
117
119
 
118
- - **Fast**: Skip the manual git clone, cd, install dance
119
- - **Smart**: Automatically detects what kind of project you're working with
120
- - **Convenient**: Opens your IDE and starts development servers automatically
121
- - **Reliable**: Handles edge cases like directory conflicts and missing dependencies
120
+ Without a token, you're limited to 60 requests per hour. With a token, you get 5,000 requests per hour.