@django-stack/cli 0.0.0-stage → 0.1.0

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 (81) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +33 -2
  3. package/dist/bin.d.ts +1 -0
  4. package/dist/bin.js +1305 -0
  5. package/dist/index.d.ts +251 -0
  6. package/dist/index.js +1 -0
  7. package/dist/stack-OTrWHXrO.js +712 -0
  8. package/package.json +52 -3
  9. package/templates/backend/.dockerignore +11 -0
  10. package/templates/backend/Dockerfile +45 -0
  11. package/templates/backend/config/__init__.py +0 -0
  12. package/templates/backend/config/asgi.py +7 -0
  13. package/templates/backend/config/settings.py +87 -0
  14. package/templates/backend/config/studio.py +20 -0
  15. package/templates/backend/config/urls.py +9 -0
  16. package/templates/backend/config/wsgi.py +7 -0
  17. package/templates/backend/conftest.py +7 -0
  18. package/templates/backend/content/__init__.py +0 -0
  19. package/templates/backend/content/admin.py +107 -0
  20. package/templates/backend/content/apps.py +6 -0
  21. package/templates/backend/content/blocks.py +51 -0
  22. package/templates/backend/content/migrations/0001_initial.py +418 -0
  23. package/templates/backend/content/migrations/__init__.py +0 -0
  24. package/templates/backend/content/models.py +234 -0
  25. package/templates/backend/content/seed.py +153 -0
  26. package/templates/backend/content/tests/__init__.py +0 -0
  27. package/templates/backend/content/tests/test_api.py +73 -0
  28. package/templates/backend/entrypoint.sh +27 -0
  29. package/templates/backend/manage.py +16 -0
  30. package/templates/backend/pyproject.toml +33 -0
  31. package/templates/backend/vendor/.gitkeep +0 -0
  32. package/templates/base/.github/workflows/deploy.yml +70 -0
  33. package/templates/base/AGENTS.md +78 -0
  34. package/templates/base/CLAUDE.md +1 -0
  35. package/templates/base/Caddyfile +51 -0
  36. package/templates/base/README.md +87 -0
  37. package/templates/base/SECURITY.md +12 -0
  38. package/templates/base/compose.yaml +303 -0
  39. package/templates/base/env.example +80 -0
  40. package/templates/base/gitignore +15 -0
  41. package/templates/base/package.json +21 -0
  42. package/templates/frontend-astro/.dockerignore +4 -0
  43. package/templates/frontend-astro/Dockerfile +32 -0
  44. package/templates/frontend-astro/astro.config.mjs +38 -0
  45. package/templates/frontend-astro/package.json +31 -0
  46. package/templates/frontend-astro/public/favicon.svg +1 -0
  47. package/templates/frontend-astro/src/components/Blocks.astro +32 -0
  48. package/templates/frontend-astro/src/components/ContactForm.astro +68 -0
  49. package/templates/frontend-astro/src/components/Image.astro +34 -0
  50. package/templates/frontend-astro/src/components/PostCard.astro +41 -0
  51. package/templates/frontend-astro/src/components/PostList.astro +39 -0
  52. package/templates/frontend-astro/src/components/RichText.astro +14 -0
  53. package/templates/frontend-astro/src/components/Seo.astro +20 -0
  54. package/templates/frontend-astro/src/components/blocks/CallToAction.astro +23 -0
  55. package/templates/frontend-astro/src/components/blocks/Image.astro +24 -0
  56. package/templates/frontend-astro/src/components/blocks/Quote.astro +10 -0
  57. package/templates/frontend-astro/src/components/blocks/Text.astro +8 -0
  58. package/templates/frontend-astro/src/layouts/Base.astro +122 -0
  59. package/templates/frontend-astro/src/lib/api.ts +24 -0
  60. package/templates/frontend-astro/src/lib/cache.ts +58 -0
  61. package/templates/frontend-astro/src/lib/headless.ts +344 -0
  62. package/templates/frontend-astro/src/middleware.ts +69 -0
  63. package/templates/frontend-astro/src/pages/404.astro +13 -0
  64. package/templates/frontend-astro/src/pages/[...slug].astro +21 -0
  65. package/templates/frontend-astro/src/pages/blog/[slug].astro +50 -0
  66. package/templates/frontend-astro/src/pages/blog/index.astro +15 -0
  67. package/templates/frontend-astro/src/pages/category/[slug].astro +25 -0
  68. package/templates/frontend-astro/src/pages/index.astro +28 -0
  69. package/templates/frontend-astro/src/pages/preview/exit.ts +7 -0
  70. package/templates/frontend-astro/src/pages/preview/index.ts +26 -0
  71. package/templates/frontend-astro/src/pages/revalidate.ts +19 -0
  72. package/templates/frontend-astro/src/pages/robots.txt.ts +7 -0
  73. package/templates/frontend-astro/src/pages/rss.xml.ts +19 -0
  74. package/templates/frontend-astro/src/pages/sitemap.xml.ts +29 -0
  75. package/templates/frontend-astro/src/pages/tag/[slug].astro +24 -0
  76. package/templates/frontend-astro/src/styles/global.css +101 -0
  77. package/templates/frontend-astro/test/blocks.test.ts +42 -0
  78. package/templates/frontend-astro/test/cache.test.ts +22 -0
  79. package/templates/frontend-astro/tsconfig.json +5 -0
  80. package/templates/frontend-astro/vendor/.gitkeep +0 -0
  81. package/templates/frontend-astro/vitest.config.ts +8 -0
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Leon van der Grient
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md CHANGED
@@ -1,3 +1,34 @@
1
- # Temporary Holding Version
1
+ # @django-stack/cli
2
2
 
3
- This version is a temporary placeholder for this package. An operational version to replace this has been submitted for review and is awaiting a staged release.
3
+ The production-ready Django, batteries included stack. Create and manage DjangoStack projects: a Django backend, a frontend, Postgres and Docker Compose in one command.
4
+
5
+ ```bash
6
+ npx @django-stack/cli init my-site
7
+ cd my-site
8
+ docker compose up
9
+ ```
10
+
11
+ | Command | Description |
12
+ |---------|-------------|
13
+ | `init [directory]` | Create a project. Flags: `--name`, `--preset`, `--frontend`, `--postgres`, `--analytics`, `--tasks`, `--cache`, `--notifications`, `--captcha`, `--storage`, `--package-manager`, `--database-url`, `--time-zone`, `--no-demo-content`, `--no-git`, `--start`, `--yes` |
14
+ | `production [directory]` | Write `.env.production` for a server. Flags: `--domain`, `--email-url`, `--force`, `--yes` |
15
+ | `preset [preset]` | Print the preset code of a stack, or the stack of a code |
16
+ | `doctor [directory]` | Check a project and its running services |
17
+ | `secret [bytes]` | Print a random secret |
18
+ | `completion <shell>` | Print a Tab completion script for zsh, bash, fish or PowerShell |
19
+
20
+ The command is `dstack`. The first time you run the CLI with `npx`, it
21
+ offers to install `dstack` globally; or run
22
+ `npm install --global @django-stack/cli` yourself. Turn the offer off with
23
+ `--no-install-prompt` or `DJANGO_STACK_NO_INSTALL_PROMPT=1`.
24
+
25
+ Run `dstack help <command>` for the options of a command. Each command
26
+ checks for a newer version once a day; turn that off with
27
+ `--no-update-check` or `DJANGO_STACK_NO_UPDATE_CHECK=1`.
28
+
29
+ Read the [documentation](https://github.com/dwarsbit/django-stack/tree/main/website/docs) of
30
+ [DjangoStack](https://github.com/dwarsbit/django-stack).
31
+
32
+ ## License
33
+
34
+ MIT
package/dist/bin.d.ts ADDED
@@ -0,0 +1 @@
1
+ export {}