Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
@app-generator
app-generator
Follow
View app-generator's full-sized avatar
🎯
Focusing

App Generator app-generator

🎯
Focusing

Highlights

  • Pro

Block or report app-generator

Block user

Prevent this user from interacting with your repositories and sending you notifications. Learn more aboutblocking users.

You must be logged in to block users.

Please don't include any personal information such as legal names or email addresses. Maximum 100 characters, markdown supported. This note will be visible to only you.
Report abuse

Contact GitHub support about this user’s behavior. Learn more aboutreporting abuse.

Report abuse
app-generator/README.md

Open-Source Tools for solo-devs, students and companies - GenerateDigital Products,Update legacy code by chat, Inject new modules, Software Auto-healing, AI, Deployment automation (any provider), Docker, K8s.


Features


Stack

  • Python/Django
  • React
  • Docker
  • CI/CD - LIVE Deploy on Digital Ocean

Manual Build

Step #1 - Download the code

$ git clone https://github.com/app-generator/app-generator.git$cd app-generator

Step #2 - Install modules

$ virtualenv env$source env/bin/activate$ pip install -r requirements.txt

Step #3 - Set Up Database

$ python manage.py makemigrations$ python manage.py migrate

Step #4 - Create the ENV file

The.env can be created from theenv.sample file, provided in the root of the project

$ cp env.sample .env

Step #5 - Compile UI (that uses Tailwind)

$ pnpm i$ pnpm run build

Step #5 - Executecollectstatic for Django statics

$ python manage.py collectstatic$ python manage.py migrate

Start the APP

$ python manage.py createsuperuser# create the admin$ python manage.py runserver# start the project

At this point, the app runs athttp://127.0.0.1:8000/.


The Documentation being generated by, the compilation requires a linux box

$cd docs&& rm -rf build&& make html# Or via a while loop$cd docs;whiletrue;do rm -rf build/; make html; sleep 10;done

The output is saved ondocs/build and rendered on/docs/ URI


CLI Interface

All CLI tools are listed bydev_tools subcommand:

$ python manage.py dev_tools

Below sections explains each dev_tool added to the codebase - If somethings is not working in your environment, please contactsupport.

Generate Code

Django Starters

$ python manage.py tool_generator -f sources/input-django-template-soft.json# Generate a new Django Starter, Soft Design

Flask Starters

$ python manage.py tool_generator -f sources/input-flask-template-datta.json# Generate a new Flask Starter, Datta Able Design

The generated code is saved ingenerated_code DIR. Open the sources using your favorite editor and start the project.


Generate Project Template

Using this tool, we can generate a JSON template used later by the generator

$ python manage.py tool_generator_interactive_django -i# Print HELP$ python manage.py tool_generator_interactive_django# Generate JSON File$ python manage.py tool_generator_interactive_flask# Generate JSON File...# (Truncated Output)$ python manage.py tool_generator_interactive_django[?] Project Friendly Name: Some Django project[?] The Backend Framework:> django   flask (soon)   nodejs (soon)[?] The UI Kit:> datta   volt   soft-dashboard[?] The Database:> sqlite   mysql   pgsql...# (Truncated Output)...> File saved = sources\Nt5QWHGI_django_template.json> HOW to generate code:|-- python manage.py tool_generator -f sources/Nt5QWHGI_django_template.json

By running the sugegsted command, we should be able to generate a valid Django Project.


Upload to GitHub

Note: For having SUCCESS on this operation, aGITHUB_KEY is required in.env - readmore.

$ python manage.py tool_github_uploader -i# Print HELP$ python manage.py tool_github_uploader -d generated_code/GENERATED_PROJECT -k GITHUB_KEY

Once the operation is finished, the generated project should be saved under the account associated with theGITHUB_KEY.


Inspect DB (sqlite, MySql, PgSql)

# SQLite scan$ python manage.py tool_db_processor -f media/tools/db_inspect/db_sqlite.json# OR# MySql scan$ python manage.py tool_db_processor -f media/tools/db_inspect/db_mysql.json...# (Truncated Output)> Processing media/tools/db_inspect/db_sqlite.json|--type: db|-- DB driver: SQLITE|-- DB name: media/tools/common/sample.sqlite3|-- DB host: None|-- DB port: None|-- DB user: None|-- DB pass: None> Dump datafor [api_user_user]> Dump datafor [api_authentication_activesession]> Dump datafor [auth_group]> Dump datafor [api_user_user_groups]> Dump datafor [django_content_type]> Dump datafor [auth_permission]> Dump datafor [api_user_user_user_permissions]> Dump datafor [auth_group_permissions]> Dump datafor [django_admin_log]> Dump datafor [django_migrations]> Dump datafor [django_session]

The SQL dump is done in thetmp DIRECTORY

ROOT|-- tmp|-- 05_27_58_SQLITE.sql|-- 05_28_04_SQLITE_api_user_user

Migrate DB

Note: the feature works with SQLite, MySql and PostgreSQL.

The source and target DB credentials should be provided in JSON format. Here are the provided samples

How to use it:

$ python manage.py tool_db_migrator -s DB_SOURCE.json -t DB_TARGET.json# Perform Checks$ python manage.py tool_db_migrator -s DB_SOURCE.json -t DB_TARGET.json --migrate# Migrate the data

CSV processor

Authenticated users can process CSV files and apply transformers.

DEMO:https://app-generator.dev/tools/csv-processor/


Inspect CSV Files

$ python manage.py tool_inspect_source -f media/tools/csv/csv_inspect.json# Truncated output$ python manage.py tool_inspect_source -f media/tools/csv/csv_inspect.json -k# Print all rows# OR for distant CSV files$ python manage.py tool_inspect_source -f media/tools/csv/csv_inspect_distant.json...# (Truncated Output)> Processing media/tools/csv/csv_inspect.json|-- file: media/tools/csv/titanic.csv|-- type: csv{'PassengerId': {'type':'int64'},'Survived': {'type':'int64'},'Pclass': {'type':'int64'},'Name': {'type':'object'},'Sex': {'type':'object'},'Age': {'type':'float64'},'SibSp': {'type':'int64'},'Parch': {'type':'int64'},'Ticket': {'type':'object'},'Fare': {'type':'float64'},'Cabin': {'type':'object'},'Embarked': {'type':'object'}}[1] - PassengerId,Survived,Pclass,Name,Sex,Age,SibSp,Parch,Ticket,Fare,Cabin,Embarked[2] - 1,0,3,"Braund, Mr. Owen Harris",male,22,1,0,A/5 21171,7.25,,S[3] - 2,1,1,"Cumings, Mrs. John Bradley (Florence Briggs Thayer)",female,38,1,0,PC 17599,71.2833,C85,C[4] - 3,1,3,"Heikkinen, Miss. Laina",female,26,0,0,STON/O2. 3101282,7.925,,S[5] - 4,1,1,"Futrelle, Mrs. Jacques Heath (Lily May Peel)",female,35,1,0,113803,53.1,C123,S[6] - 5,0,3,"Allen, Mr. William Henry",male,35,0,0,373450,8.05,,S[7] - 6,0,3,"Moran, Mr. James",male,,0,0,330877,8.4583,,Q[8] - 7,0,1,"McCarthy, Mr. Timothy J",male,54,0,0,17463,51.8625,E46,S[9] - 8,0,3,"Palsson, Master. Gosta Leonard",male,2,3,1,349909,21.075,,S[10] - 9,1,3,"Johnson, Mrs. Oscar W (Elisabeth Vilhelmina Berg)",female,27,0,2,347742,11.1333,,S...

List available commands

$ python manage.pyhelp# (Truncated Output)Type'manage.py help <subcommand>'forhelp on a specific subcommand.Available subcommands:...[cli]    help_print_apps    help_print_cfg    help_print_models...

List Registered Apps

$ python manage.py help_print_apps# (Truncated Output) APP -> Webpack Loader APP -> Administration APP -> Authentication and Authorization ...

List Registered Models

$ python manage.py help_print_models# (Truncated Output)APP -> GithubAPP -> GoogleAPP -> Django_QuillAPP -> Celery Results|--> django_celery_results.models.TaskResult|--> id: AutoField|--> task_id: CharField|--> periodic_task_name: CharField|--> task_name: CharField|--> task_args: TextField|--> task_kwargs: TextField|--> status: CharField|--> worker: CharField|--> content_type: CharField|--> content_encoding: CharField|--> result: TextField|--> date_created: DateTimeField|--> date_done: DateTimeField|--> traceback: TextField|--> meta: TextField|--> django_celery_results.models.ChordCounter|--> id: AutoField|--> group_id: CharField|--> sub_tasks: TextField|--> count: PositiveIntegerField|--> django_celery_results.models.GroupResult|--> id: AutoField|--> group_id: CharField|--> date_created: DateTimeField|--> date_done: DateTimeField|--> content_type: CharField|--> content_encoding: CharField|--> result: TextField

Celery (async tasks)

  • Make sure you have a Redis Server running:redis://localhost:6379
    • $ redis-cli and typeping
  • In the base directory insidetasks_scripts folder you need to write your scripts file.
  • Run the celery command from the CLI.
$export DJANGO_SETTINGS_MODULE="core.settings"  $ celery -A core worker -l info -B

Executed Tasks,tasks_scripts DIR as defined in theEXEC Schedule

The output for each task can be found in theLOGS Directory.

Here is a LOG sample generated by a critical task that runs at every 5min:


Team

Core

Developers/Contractors


LICENSE

@EULA



Crafted and actively supported byAppSeed -support@appseed.us

PinnedLoading

  1. introintroPublic

    App Generator - Deliver your projects faster | AppSeed

    54 13

  2. admin-dashboardsadmin-dashboardsPublic

    Admin Dashboards - Open-Source and Free | App-Generator.dev

    394 47

  3. django-dashboardsdjango-dashboardsPublic template

    Django Dashboards - Admin Panels coded in Django | App-Generator.dev

    394 72

  4. docsdocsPublic

    App Generator - The Official Documentation | AppSeed

    JavaScript 1 1


[8]ページ先頭

©2009-2025 Movatter.jp