{"id":15612402,"url":"https://github.com/vjousse/vim-for-humans-website","last_synced_at":"2025-04-28T17:02:09.885Z","repository":{"id":36341390,"uuid":"40646116","full_name":"vjousse/vim-for-humans-website","owner":"vjousse","description":"Website (python3, Flask, babel, stripe) for the ebook Vim for humans","archived":false,"fork":false,"pushed_at":"2025-01-08T20:40:33.000Z","size":45547,"stargazers_count":8,"open_issues_count":3,"forks_count":1,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-04-18T18:33:17.114Z","etag":null,"topics":["ebook","flask","vim"],"latest_commit_sha":null,"homepage":"https://vimebook.com","language":"CSS","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/vjousse.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2015-08-13T07:55:11.000Z","updated_at":"2024-07-10T15:10:04.000Z","dependencies_parsed_at":"2023-01-17T01:17:51.416Z","dependency_job_id":"b0b52d82-2c41-4d85-a44f-b98ebac16a8f","html_url":"https://github.com/vjousse/vim-for-humans-website","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vjousse%2Fvim-for-humans-website","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vjousse%2Fvim-for-humans-website/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vjousse%2Fvim-for-humans-website/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vjousse%2Fvim-for-humans-website/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/vjousse","download_url":"https://codeload.github.com/vjousse/vim-for-humans-website/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251352525,"owners_count":21575859,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ebook","flask","vim"],"created_at":"2024-10-03T06:42:33.614Z","updated_at":"2025-04-28T17:02:09.868Z","avatar_url":"https://github.com/vjousse.png","language":"CSS","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Installation\n\nFirst, be sure to sign up for a [Stripe account](https://stripe.com/) (the payment platform) and go to the [API page](https://dashboard.stripe.com/account/apikeys) to get your keys.\n\nIn this readme, I'm using 3 sample keys:\n\n    PUBLISHABLE_KEY=pk_test_4aZnwTrOtTfNSxs8KtI1a3LC\n    SECRET_KEY=sk_test_4aZnq9QgKUcJ2cPp9dGaidOT\n    ENDPOINT_SECRET=whsec_AjrfPgBKPZhCnU5grqtuhDnXU5OYA9zf\n\n## Pip / python env\n\n    pip install virtualenv\n    virtualenv -p /usr/bin/python3 env\n    . ./env/bin/activate\n    pip install -r requirements.txt\n\n## Create db\n\n    PUBLISHABLE_KEY=pk_test_4aZnwTrOtTfNSxs8KtI1a3LC SECRET_KEY=sk_test_4aZnq9QgKUcJ2cPp9dGaidOT ENDPOINT_SECRET=whsec_AjrfPgBKPZhCnU5grqtuhDnXU5OYA9zf python\n    from app import db,app\n    app.app_context().push()\n    db.create_all()\n\nYou can use \u003cCtrl-d\u003e to exit the python shell. The database should have been created under the `instance/` directory.\n\n## Translations\n\n### Extract strings to translate\n\n    pybabel extract -F babel.cfg -o messages.pot ./templates\n\n### Update messages.po\n\n    pybabel update -i messages.pot -d translations\n\n### Finally compile\n\n    pybabel compile -d translations\n\n## Run\n\nDepending on the keys, it will run in production/test mode for stripe.\n\n    ENDPOINT_SECRET=\"whsec_AjrfPgBKPZhCnU5grqtuhDnXU5OYA9zf\" PUBLISHABLE_KEY=pk_test_4aZnwTrOtTfNSxs8KtI1a3LC SECRET_KEY=sk_test_4aZnq9QgKUcJ2cPp9dGaidOT python app.py\n\nThe dev server should be listening on http://localhost:5000\n\n# Supervisor\n\nOf course, you need to replace the test keys by the live one.\n\n    [program:vimebook]\n    environment = PATH=\"/home/vimebook/python/vim-for-humans-website/env/bin:%(ENV_PATH)s\",PUBLISHABLE_KEY=\"pk_test_4aZnwTrOtTfNSxs8KtI1a3LC\",SECRET_KEY=\"sk_test_4aZnq9QgKUcJ2cPp9dGaidOT\",ENDPOINT_SECRET=\"whsec_AjrfPgBKPZhCnU5grqtuhDnXU5OYA9zf\"\n    command = /home/vimebook/python/vim-for-humans-website/gunicorn_start.sh ; Command to start app\n    user = vimebook ; User to run as\n    stdout_logfile = /home/vimebook/python/vim-for-humans-website/log/gunicorn_supervisor.log ; Where to write log messages\n    redirect_stderr = true ; Save stderr in the same log\n\nSupervisorctl commands:\n\n    supervisorctl reread\n    supervisorctl update\n\n# Extract parts of the PDF\n\n    pdftk vim-pour-les-humains.pdf cat 7-23 output vim-pour-les-humains-extrait.pdf\n\n# Good reads\n\n- https://eff.iciently.com/blog/stripe_checkout.html\n- http://www.jeffknupp.com/blog/2014/01/18/python-and-flask-are-ridiculously-powerful/\n- http://blog.miguelgrinberg.com/post/the-flask-mega-tutorial-part-xiv-i18n-and-l10n\n- https://www.safaribooksonline.com/blog/2013/11/27/flask-internationalization-and-localization/\n- http://damyanon.net/\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvjousse%2Fvim-for-humans-website","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fvjousse%2Fvim-for-humans-website","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvjousse%2Fvim-for-humans-website/lists"}