@lastbrain/app 0.1.15 → 0.1.17

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.
@@ -750,53 +750,76 @@ async function createGitIgnore(targetDir, force) {
750
750
  const gitignorePath = path.join(targetDir, ".gitignore");
751
751
  if (!fs.existsSync(gitignorePath) || force) {
752
752
  console.log(chalk.yellow("\n📝 Création de .gitignore..."));
753
- const gitignoreContent = `# Dependencies
754
- node_modules/
755
- .pnp
756
- .pnp.js
757
-
758
- # Testing
759
- coverage/
760
-
761
- # Next.js
762
- .next/
763
- out/
764
- build/
765
- dist/
766
-
767
- # Production
768
- *.log*
769
-
770
- # Misc
771
- .DS_Store
772
- *.pem
753
+ // Copier le fichier .gitignore depuis le template
754
+ const templateGitignorePath = path.join(__dirname, "../templates/gitignore/.gitignore");
755
+ if (fs.existsSync(templateGitignorePath)) {
756
+ await fs.copyFile(templateGitignorePath, gitignorePath);
757
+ }
758
+ else {
759
+ // Fallback si le template n'existe pas
760
+ const gitignoreContent = `# ===========================================
761
+ # GENERATED BY LASTBRAIN
762
+ # ===========================================
773
763
 
774
- # Debug
764
+ # Node
765
+ node_modules/
775
766
  npm-debug.log*
767
+ pnpm-debug.log*
776
768
  yarn-debug.log*
777
769
  yarn-error.log*
778
770
 
779
- # Local env files
771
+ # Environment
780
772
  .env
781
- .env*.local
782
- .env.production
783
-
784
- # Vercel
785
- .vercel
773
+ .env.*
774
+ !.env.example
786
775
 
787
- # Typescript
788
- *.tsbuildinfo
789
- next-env.d.ts
776
+ # Next.js
777
+ .next/
778
+ out/
779
+ dist/
780
+ build/
790
781
 
791
782
  # Supabase
792
783
  supabase/.temp/
784
+ supabase/functions/.netlify/
785
+ supabase/functions/node_modules/
793
786
  supabase/.branches/
794
787
 
795
- # LastBrain generated
796
- **/navigation.generated.ts
797
- **/routes.generated.ts
788
+ # Logs
789
+ logs
790
+ *.log
791
+ *.log.*
792
+
793
+ # OS / Editor
794
+ .DS_Store
795
+ Thumbs.db
796
+ .idea/
797
+ .vscode/
798
+ *.swp
799
+
800
+ # Local backups
801
+ *.sql
802
+ *.sql.zip
803
+ backup/
804
+ tmp/
805
+
806
+ # Coverage
807
+ coverage/
808
+ *.lcov
809
+
810
+ # Generated by module-build
811
+ app/navigation.generated.ts
812
+ app/routes.generated.ts
813
+ app/menu.generated.ts
814
+
815
+ # Generated app-shell overrides
816
+ app/(public)/
817
+ app/(auth)/
818
+ app/(admin)/
819
+ app/layout.tsx
798
820
  `;
799
- await fs.writeFile(gitignorePath, gitignoreContent);
821
+ await fs.writeFile(gitignorePath, gitignoreContent);
822
+ }
800
823
  console.log(chalk.green("✓ .gitignore créé"));
801
824
  }
802
825
  }
@@ -1 +1 @@
1
- {"version":3,"file":"DefaultDoc.d.ts","sourceRoot":"","sources":["../../src/templates/DefaultDoc.tsx"],"names":[],"mappings":"AAaA,wBAAgB,oBAAoB,4CAioBnC"}
1
+ {"version":3,"file":"DefaultDoc.d.ts","sourceRoot":"","sources":["../../src/templates/DefaultDoc.tsx"],"names":[],"mappings":"AAaA,wBAAgB,oBAAoB,4CAmoBnC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lastbrain/app",
3
- "version": "0.1.15",
3
+ "version": "0.1.17",
4
4
  "description": "Framework modulaire Next.js avec CLI et système de modules",
5
5
  "private": false,
6
6
  "type": "module",
@@ -41,8 +41,8 @@
41
41
  "react": "^19.0.0",
42
42
  "react-dom": "^19.0.0",
43
43
  "@lastbrain/core": "0.1.0",
44
- "@lastbrain/module-auth": "0.1.1",
45
- "@lastbrain/ui": "0.1.3"
44
+ "@lastbrain/ui": "0.1.3",
45
+ "@lastbrain/module-auth": "0.1.1"
46
46
  },
47
47
  "peerDependencies": {
48
48
  "next": ">=15.0.0"
@@ -872,53 +872,79 @@ async function createGitIgnore(targetDir: string, force: boolean) {
872
872
  if (!fs.existsSync(gitignorePath) || force) {
873
873
  console.log(chalk.yellow("\n📝 Création de .gitignore..."));
874
874
 
875
- const gitignoreContent = `# Dependencies
876
- node_modules/
877
- .pnp
878
- .pnp.js
879
-
880
- # Testing
881
- coverage/
882
-
883
- # Next.js
884
- .next/
885
- out/
886
- build/
887
- dist/
888
-
889
- # Production
890
- *.log*
875
+ // Copier le fichier .gitignore depuis le template
876
+ const templateGitignorePath = path.join(
877
+ __dirname,
878
+ "../templates/gitignore/.gitignore"
879
+ );
891
880
 
892
- # Misc
893
- .DS_Store
894
- *.pem
881
+ if (fs.existsSync(templateGitignorePath)) {
882
+ await fs.copyFile(templateGitignorePath, gitignorePath);
883
+ } else {
884
+ // Fallback si le template n'existe pas
885
+ const gitignoreContent = `# ===========================================
886
+ # GENERATED BY LASTBRAIN
887
+ # ===========================================
895
888
 
896
- # Debug
889
+ # Node
890
+ node_modules/
897
891
  npm-debug.log*
892
+ pnpm-debug.log*
898
893
  yarn-debug.log*
899
894
  yarn-error.log*
900
895
 
901
- # Local env files
896
+ # Environment
902
897
  .env
903
- .env*.local
904
- .env.production
905
-
906
- # Vercel
907
- .vercel
898
+ .env.*
899
+ !.env.example
908
900
 
909
- # Typescript
910
- *.tsbuildinfo
911
- next-env.d.ts
901
+ # Next.js
902
+ .next/
903
+ out/
904
+ dist/
905
+ build/
912
906
 
913
907
  # Supabase
914
908
  supabase/.temp/
909
+ supabase/functions/.netlify/
910
+ supabase/functions/node_modules/
915
911
  supabase/.branches/
916
912
 
917
- # LastBrain generated
918
- **/navigation.generated.ts
919
- **/routes.generated.ts
913
+ # Logs
914
+ logs
915
+ *.log
916
+ *.log.*
917
+
918
+ # OS / Editor
919
+ .DS_Store
920
+ Thumbs.db
921
+ .idea/
922
+ .vscode/
923
+ *.swp
924
+
925
+ # Local backups
926
+ *.sql
927
+ *.sql.zip
928
+ backup/
929
+ tmp/
930
+
931
+ # Coverage
932
+ coverage/
933
+ *.lcov
934
+
935
+ # Generated by module-build
936
+ app/navigation.generated.ts
937
+ app/routes.generated.ts
938
+ app/menu.generated.ts
939
+
940
+ # Generated app-shell overrides
941
+ app/(public)/
942
+ app/(auth)/
943
+ app/(admin)/
944
+ app/layout.tsx
920
945
  `;
921
- await fs.writeFile(gitignorePath, gitignoreContent);
946
+ await fs.writeFile(gitignorePath, gitignoreContent);
947
+ }
922
948
  console.log(chalk.green("✓ .gitignore créé"));
923
949
  }
924
950
  }
@@ -381,17 +381,13 @@ where email = 'votre@email.com';`}
381
381
  </Snippet>
382
382
  </div>
383
383
  <div>
384
- <h3 className="text-lg font-semibold mb-2">
385
- Build de production
386
- </h3>
384
+ <h3 className="text-lg font-semibold mb-2">Build de production</h3>
387
385
  <Snippet symbol="" hideSymbol className="text-sm">
388
386
  pnpm build
389
387
  </Snippet>
390
388
  </div>
391
389
  <div>
392
- <h3 className="text-lg font-semibold mb-2">
393
- Développer un module
394
- </h3>
390
+ <h3 className="text-lg font-semibold mb-2">Développer un module</h3>
395
391
  <Snippet symbol="" hideSymbol className="text-sm mb-2">
396
392
  cd packages/module-auth
397
393
  </Snippet>
@@ -449,7 +445,9 @@ where email = 'votre@email.com';`}
449
445
  </CardHeader>
450
446
  <CardBody className="space-y-4">
451
447
  <div>
452
- <h3 className="text-lg font-semibold mb-2">1. Modifier un module</h3>
448
+ <h3 className="text-lg font-semibold mb-2">
449
+ 1. Modifier un module
450
+ </h3>
453
451
  <p className="text-sm text-slate-600 dark:text-slate-400 mb-2">
454
452
  Éditez les fichiers dans{" "}
455
453
  <code className="px-2 py-1 bg-slate-100 dark:bg-slate-800 rounded">
@@ -458,7 +456,9 @@ where email = 'votre@email.com';`}
458
456
  </p>
459
457
  </div>
460
458
  <div>
461
- <h3 className="text-lg font-semibold mb-2">2. Compiler le module</h3>
459
+ <h3 className="text-lg font-semibold mb-2">
460
+ 2. Compiler le module
461
+ </h3>
462
462
  <Snippet symbol="" hideSymbol className="text-sm mb-2">
463
463
  cd packages/module-auth
464
464
  </Snippet>
@@ -467,7 +467,9 @@ where email = 'votre@email.com';`}
467
467
  </Snippet>
468
468
  </div>
469
469
  <div>
470
- <h3 className="text-lg font-semibold mb-2">3. Régénérer les pages</h3>
470
+ <h3 className="text-lg font-semibold mb-2">
471
+ 3. Régénérer les pages
472
+ </h3>
471
473
  <Snippet symbol="" hideSymbol className="text-sm mb-2">
472
474
  cd apps/my-app
473
475
  </Snippet>