diff --git a/changelog/index.html b/changelog/index.html index b521cbf4..02096f32 100644 --- a/changelog/index.html +++ b/changelog/index.html @@ -1 +1 @@ -Changelog - Python Project Generation Tool
Skip to content

Changelog

This is an auto-generated log of all the changes that have been made to the project since the first release.

This project adheres to Semantic Versioning.

0.10.1 (March 12, 2024)

Closed Issues

  • Empty string for 'homepage' in pyproject.html crashes Poetry (#317) by seapagan

Testing

Bug Fixes

  • Fix bug where bad homepage field crashes poetry install (#318) by seapagan

Refactoring

  • Convert settings module to use new get_settings() method (#309) by seapagan

Documentation

  • Update Docs to mention previous linting changes (#305) by seapagan

Dependency Updates

Full Changelog | Diff | Patch

v0.10.0 (March 06, 2024)

Closed Issues

  • When missing the config file, it does not properly read the users Git username/email (#291) by seapagan

Bug Fixes

Dependency Updates

Full Changelog | Diff | Patch

v0.9.5 (March 04, 2024)

Closed Issues

  • For standalone app, the suggested GitHub URL is wrong, it should be the same as if the app was a package (#296) by seapagan
  • Template deps need updating and template config files need a freshening (#294) by seapagan
  • Standalone app should have the ending text changed. (#293) by seapagan
  • If creating a standalone, poetry install should set 'package-mode=false' in the pyproject.toml (#292) by seapagan

Merged Pull Requests

New Features

  • Update deps and template, freshen the template config files. (#297) by seapagan

Testing

  • Continue writing tests. (#267) by seapagan
  • Add a testing stage to CI with coverage reports from codacy (#266) by seapagan

Bug Fixes

  • Ask for repo name and offer to create for both type of projects (#298) by seapagan
  • Fix several issues with generating standalone projects (#295) by seapagan

Dependency Updates

Full Changelog | Diff | Patch

v0.9.4 (December 11, 2023)

This is a security release that fixes a vulnerability in the 'cryptography' package.

Refactoring

  • Update pre commit config to use poetry-export-plugin directly (#203) by seapagan

Dependency Updates

Full Changelog | Diff | Patch

v0.9.3 (October 29, 2023)

Refactoring

Dependency Updates

Full Changelog | Diff | Patch

v0.9.2 (October 24, 2023)

Merged Pull Requests

Dependency Updates

Full Changelog | Diff | Patch

v0.9.1 (October 12, 2023)

Bug Fixes

Dependency Updates

Full Changelog | Diff | Patch

v0.9.0 (October 10, 2023)

Merged Pull Requests

New Features

  • Migrate settings to my 'simple-toml-settings' library (#146) by seapagan

Dependency Updates

Full Changelog | Diff | Patch

v0.8.0 (October 04, 2023)

Merged Pull Requests

New Features

  • Automatically create a GitHub repository for the new project (#134) by seapagan

Refactoring

Dependency Updates

Full Changelog | Diff | Patch

v0.7.0 (October 01, 2023)

Merged Pull Requests

New Features

Documentation

Dependency Updates

Full Changelog | Diff | Patch

v0.6.2 (September 24, 2023)

Closed Issues

Merged Pull Requests

  • Add poe tasks for documentation if mkdocs enabled (#100) by seapagan

Bug Fixes

Full Changelog | Diff | Patch

v0.6.1 (September 23, 2023)

Merged Pull Requests

  • Update tool versions in both pre-commit configs (#99) by seapagan

Bug Fixes

  • Fix typos and wording in the generated readme (#98) by seapagan

Documentation

  • Remove dependency spam from changelog (#97) by seapagan

Dependency Updates

Full Changelog | Diff | Patch

v0.6.0 (September 14, 2023)

New Features

  • Auto install and update 'pre commit' (#88) by seapagan
  • Add code of conduct to project and the template (#87) by seapagan
  • Add Github templates to the default output template (#86) by seapagan

Dependency Updates

Full Changelog | Diff | Patch

v0.5.1 (September 12, 2023)

New Features

Bug Fixes

  • Add missing 'requests' library to pyproject.toml (#82) by seapagan

Dependency Updates

Full Changelog | Diff | Patch

v0.5.0 (August 31, 2023)

New Features

  • Ask for homepage & repository if not standalone (#61) by seapagan
  • Update template toml and pre-commit deps (#58) by seapagan
  • Override config options from command line (#55) by seapagan
  • Check PyPI for existing packages (#46) by seapagan

Bug Fixes

Refactoring

  • Override config options from command line (#55) by seapagan

Documentation

Dependency Updates

Full Changelog | Diff | Patch

v0.4.5 (August 17, 2023)

New Features

  • Work on the TODO list. See commits for details (#44) by seapagan

Dependency Updates

Full Changelog | Diff | Patch

v0.4.4 (August 15, 2023)

New Features

Dependency Updates

Full Changelog | Diff | Patch

v0.4.3 (August 13, 2023)

New Features

Dependency Updates

Full Changelog | Diff | Patch

v0.4.2 (August 10, 2023)

  • Added a missing runtime dep (rtoml). It must have been in my venv but not in the pyproject.toml 🙄

Full Changelog | Diff | Patch

v0.4.1 (August 10, 2023)

  • Fixed bug where the first-time config file gets the wrong default template path.
  • Update the internal template pyproject.toml and .pre-commit-config.yaml to use latest dependencies

Full Changelog | Diff | Patch

v0.4.0 (August 10, 2023)

New Features

Refactoring

Dependency Updates

Full Changelog | Diff | Patch

v0.3.0 (July 30, 2023)

New Features

Refactoring

Dependency Updates

Full Changelog | Diff | Patch

v0.2.1 (July 26, 2023)

New Features

Documentation

Full Changelog | Diff | Patch

v0.2.0 (July 26, 2023)

Refactoring

Dependency Updates

Full Changelog | Diff | Patch

v0.1.0 (July 06, 2023)

Merged Pull Requests

New Features

  • Customize or remove the Package layout (#5) by seapagan

Refactoring

  • Refactor the src template layout and logic (#2) by seapagan

This changelog was generated using github-changelog-md by Seapagan

\ No newline at end of file +Changelog - Python Project Generation Tool
Skip to content

Changelog

This is an auto-generated log of all the changes that have been made to the project since the first release.

This project adheres to Semantic Versioning.

v0.10.2 (March 13, 2024)

Closed Issues

  • License name is missing in the generated README (#321) by seapagan
  • The templates for some generated files need updating (#320) by seapagan

New Features

Bug Fixes

  • Fix some bugs in the template files and update obsolete information (#325) by seapagan
  • Fix missing license name in generated README (#324) by seapagan

Dependency Updates

Full Changelog | Diff | Patch

v0.10.1 (March 12, 2024)

Closed Issues

  • Empty string for 'homepage' in pyproject.html crashes Poetry (#317) by seapagan

Testing

Bug Fixes

  • Fix bug where bad homepage field crashes poetry install (#318) by seapagan

Refactoring

  • Convert settings module to use new get_settings() method (#309) by seapagan

Documentation

  • Update Docs to mention previous linting changes (#305) by seapagan

Dependency Updates

Full Changelog | Diff | Patch

v0.10.0 (March 06, 2024)

Closed Issues

  • When missing the config file, it does not properly read the users Git username/email (#291) by seapagan

Bug Fixes

Dependency Updates

Full Changelog | Diff | Patch

v0.9.5 (March 04, 2024)

Closed Issues

  • For standalone app, the suggested GitHub URL is wrong, it should be the same as if the app was a package (#296) by seapagan
  • Template deps need updating and template config files need a freshening (#294) by seapagan
  • Standalone app should have the ending text changed. (#293) by seapagan
  • If creating a standalone, poetry install should set 'package-mode=false' in the pyproject.toml (#292) by seapagan

Merged Pull Requests

New Features

  • Update deps and template, freshen the template config files. (#297) by seapagan

Testing

  • Continue writing tests. (#267) by seapagan
  • Add a testing stage to CI with coverage reports from codacy (#266) by seapagan

Bug Fixes

  • Ask for repo name and offer to create for both type of projects (#298) by seapagan
  • Fix several issues with generating standalone projects (#295) by seapagan

Dependency Updates

Full Changelog | Diff | Patch

v0.9.4 (December 11, 2023)

This is a security release that fixes a vulnerability in the 'cryptography' package.

Refactoring

  • Update pre commit config to use poetry-export-plugin directly (#203) by seapagan

Dependency Updates

Full Changelog | Diff | Patch

v0.9.3 (October 29, 2023)

Refactoring

Dependency Updates

Full Changelog | Diff | Patch

v0.9.2 (October 24, 2023)

Merged Pull Requests

Dependency Updates

Full Changelog | Diff | Patch

v0.9.1 (October 12, 2023)

Bug Fixes

Dependency Updates

Full Changelog | Diff | Patch

v0.9.0 (October 10, 2023)

Merged Pull Requests

New Features

  • Migrate settings to my 'simple-toml-settings' library (#146) by seapagan

Dependency Updates

Full Changelog | Diff | Patch

v0.8.0 (October 04, 2023)

Merged Pull Requests

New Features

  • Automatically create a GitHub repository for the new project (#134) by seapagan

Refactoring

Dependency Updates

Full Changelog | Diff | Patch

v0.7.0 (October 01, 2023)

Merged Pull Requests

New Features

Documentation

Dependency Updates

Full Changelog | Diff | Patch

v0.6.2 (September 24, 2023)

Closed Issues

Merged Pull Requests

  • Add poe tasks for documentation if mkdocs enabled (#100) by seapagan

Bug Fixes

Full Changelog | Diff | Patch

v0.6.1 (September 23, 2023)

Merged Pull Requests

  • Update tool versions in both pre-commit configs (#99) by seapagan

Bug Fixes

  • Fix typos and wording in the generated readme (#98) by seapagan

Documentation

  • Remove dependency spam from changelog (#97) by seapagan

Dependency Updates

Full Changelog | Diff | Patch

v0.6.0 (September 14, 2023)

New Features

  • Auto install and update 'pre commit' (#88) by seapagan
  • Add code of conduct to project and the template (#87) by seapagan
  • Add Github templates to the default output template (#86) by seapagan

Dependency Updates

Full Changelog | Diff | Patch

v0.5.1 (September 12, 2023)

New Features

Bug Fixes

  • Add missing 'requests' library to pyproject.toml (#82) by seapagan

Dependency Updates

Full Changelog | Diff | Patch

v0.5.0 (August 31, 2023)

New Features

  • Ask for homepage & repository if not standalone (#61) by seapagan
  • Update template toml and pre-commit deps (#58) by seapagan
  • Override config options from command line (#55) by seapagan
  • Check PyPI for existing packages (#46) by seapagan

Bug Fixes

Refactoring

  • Override config options from command line (#55) by seapagan

Documentation

Dependency Updates

Full Changelog | Diff | Patch

v0.4.5 (August 17, 2023)

New Features

  • Work on the TODO list. See commits for details (#44) by seapagan

Dependency Updates

Full Changelog | Diff | Patch

v0.4.4 (August 15, 2023)

New Features

Dependency Updates

Full Changelog | Diff | Patch

v0.4.3 (August 13, 2023)

New Features

Dependency Updates

Full Changelog | Diff | Patch

v0.4.2 (August 10, 2023)

  • Added a missing runtime dep (rtoml). It must have been in my venv but not in the pyproject.toml 🙄

Full Changelog | Diff | Patch

v0.4.1 (August 10, 2023)

  • Fixed bug where the first-time config file gets the wrong default template path.
  • Update the internal template pyproject.toml and .pre-commit-config.yaml to use latest dependencies

Full Changelog | Diff | Patch

v0.4.0 (August 10, 2023)

New Features

Refactoring

Dependency Updates

Full Changelog | Diff | Patch

v0.3.0 (July 30, 2023)

New Features

Refactoring

Dependency Updates

Full Changelog | Diff | Patch

v0.2.1 (July 26, 2023)

New Features

Documentation

Full Changelog | Diff | Patch

v0.2.0 (July 26, 2023)

Refactoring

Dependency Updates

Full Changelog | Diff | Patch

v0.1.0 (July 06, 2023)

Merged Pull Requests

New Features

  • Customize or remove the Package layout (#5) by seapagan

Refactoring

  • Refactor the src template layout and logic (#2) by seapagan

This changelog was generated using github-changelog-md by Seapagan

\ No newline at end of file diff --git a/search/search_index.json b/search/search_index.json index 6f07b9cd..d0b85562 100644 --- a/search/search_index.json +++ b/search/search_index.json @@ -1 +1 @@ -{"config":{"lang":["en"],"separator":"[\\s\\-]+","pipeline":["stopWordFilter"]},"docs":[{"location":"","title":"Python Project Generation Tool","text":"

A fully customizable Python application to bootstrap Poetry-based boilerplate for you to start developing your Python applications quicker! Includes linting and Pytest libraries.

It will create a new directory for your project (or use the current directory), initialise a git repository, create a virtual environment, and install some basic dependencies for Testing, Linting and more. Optionally, it can also create a GitHub repository for you and push the initial commit.

Latest Version : v0.10.1

"},{"location":"#testing","title":"Testing","text":"

The generated project includes pytest and some related plugins to allow you to set up testing straight away.

Write your tests in the tests directory and run them with pytest.

"},{"location":"#linting","title":"Linting","text":"

The generated project includes Ruff for linting and code style formatting. Mypy is installed for type checking. These are set quite strictly by default, but you can edit the tools configuration in the pyproject.toml file.

"},{"location":"#customize-the-generated-project","title":"Customize the generated project","text":"

You can add extra or edited files to the generated project by adding them to the ~/.pymaker/template directory. The files in this directory will be copied into the generated project, overwriting any existing files with the same name.

It is also possible to dump the whole template into this folder or the current folder so full customization and even removal of files is possible.

"},{"location":"#pre-commit","title":"Pre-commit","text":"

The generated project uses pre-commit to run some checks on the code before it is committed. This is a great tool to help keep your code clean.

To install pre-commit, run the following command from inside your venv:

$ pre-commit install\npre-commit installed at .git/hooks/pre-commit\n
"},{"location":"#github-actions-and-configuration","title":"GitHub Actions and Configuration","text":"

By default the generated project includes a GitHub Actions workflow to run Dependabot to keep your dependencies up to date. There are also standard templates for Pull Request and Issues.

The plan is to add more workflows in the future, for example running tests and more.

"},{"location":"#changelog-generator","title":"Changelog Generator","text":"

Once you have at least one GitHub release, you can generate a CHANGELOG.md file automatically from this, using the included github-changelog-md tool.

You can run this manually by running the following command from inside your virtual environment:

$ poe changelog\n

You need to have a GitHub Personal Access Token set in the config file, see the instructions here for more information.

"},{"location":"#community-related-files","title":"Community related files","text":"

To aid in community building, the generated project includes a CODE_OF_CONDUCT.md file. This is based on the Contributor Covenant standard.

Future releases will include other Community related files (for example an AUTHORS file). There are also blank CONTRIBUTING.md and CHANGELOG.md files. The CHANGELOG.md file can be auto-generated.

"},{"location":"#contributing-to-this-project","title":"Contributing to this Project","text":"

For information on how to contribute to the project, see the CONTRIBUTING.md file in the root of the repository or on this website

"},{"location":"changelog/","title":"Changelog","text":""},{"location":"changelog/#changelog","title":"Changelog","text":"

This is an auto-generated log of all the changes that have been made to the project since the first release.

This project adheres to Semantic Versioning.

"},{"location":"changelog/#0101-march-12-2024","title":"0.10.1 (March 12, 2024)","text":"

Closed Issues

Testing

Bug Fixes

Refactoring

Documentation

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v0100-march-06-2024","title":"v0.10.0 (March 06, 2024)","text":"

Closed Issues

Bug Fixes

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v095-march-04-2024","title":"v0.9.5 (March 04, 2024)","text":"

Closed Issues

Merged Pull Requests

New Features

Testing

Bug Fixes

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v094-december-11-2023","title":"v0.9.4 (December 11, 2023)","text":"

This is a security release that fixes a vulnerability in the 'cryptography' package.

Refactoring

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v093-october-29-2023","title":"v0.9.3 (October 29, 2023)","text":"

Refactoring

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v092-october-24-2023","title":"v0.9.2 (October 24, 2023)","text":"

Merged Pull Requests

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v091-october-12-2023","title":"v0.9.1 (October 12, 2023)","text":"

Bug Fixes

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v090-october-10-2023","title":"v0.9.0 (October 10, 2023)","text":"

Merged Pull Requests

New Features

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v080-october-04-2023","title":"v0.8.0 (October 04, 2023)","text":"

Merged Pull Requests

New Features

Refactoring

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v070-october-01-2023","title":"v0.7.0 (October 01, 2023)","text":"

Merged Pull Requests

New Features

Documentation

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v062-september-24-2023","title":"v0.6.2 (September 24, 2023)","text":"

Closed Issues

Merged Pull Requests

Bug Fixes

Full Changelog | Diff | Patch

"},{"location":"changelog/#v061-september-23-2023","title":"v0.6.1 (September 23, 2023)","text":"

Merged Pull Requests

Bug Fixes

Documentation

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v060-september-14-2023","title":"v0.6.0 (September 14, 2023)","text":"

New Features

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v051-september-12-2023","title":"v0.5.1 (September 12, 2023)","text":"

New Features

Bug Fixes

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v050-august-31-2023","title":"v0.5.0 (August 31, 2023)","text":"

New Features

Bug Fixes

Refactoring

Documentation

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v045-august-17-2023","title":"v0.4.5 (August 17, 2023)","text":"

New Features

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v044-august-15-2023","title":"v0.4.4 (August 15, 2023)","text":"

New Features

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v043-august-13-2023","title":"v0.4.3 (August 13, 2023)","text":"

New Features

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v042-august-10-2023","title":"v0.4.2 (August 10, 2023)","text":"

Full Changelog | Diff | Patch

"},{"location":"changelog/#v041-august-10-2023","title":"v0.4.1 (August 10, 2023)","text":"

Full Changelog | Diff | Patch

"},{"location":"changelog/#v040-august-10-2023","title":"v0.4.0 (August 10, 2023)","text":"

New Features

Refactoring

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v030-july-30-2023","title":"v0.3.0 (July 30, 2023)","text":"

New Features

Refactoring

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v021-july-26-2023","title":"v0.2.1 (July 26, 2023)","text":"

New Features

Documentation

Full Changelog | Diff | Patch

"},{"location":"changelog/#v020-july-26-2023","title":"v0.2.0 (July 26, 2023)","text":"

Refactoring

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v010-july-06-2023","title":"v0.1.0 (July 06, 2023)","text":"

Merged Pull Requests

New Features

Refactoring

This changelog was generated using github-changelog-md by Seapagan

"},{"location":"configuration/","title":"Configuration","text":""},{"location":"configuration/#configuration-file","title":"Configuration file","text":"

This app needs minimal configuration, most options default to True. The configuration is stored in a TOML file in a sub-folder of the user's home directory. By default (and currently the only option) this file is stored in ~/.pymaker/config.toml. An example of this file is:

[pymaker]\nauthor_email = \"user@server.com\"\nauthor_name = \"Python User\"\ndefault_license = \"MIT\"\ngithub_username = \"githubuser\" # optional\ngithub_token = \"ghp_1234567890abcdefghij\" # optional\ngithub_protocol = \"ssh\"\ninclude_linters = true\ninclude_mkdocs = true\ninclude_testing = true\ninstall_pre_commit = true\nschema_version = \"1.0\" # for internal use, generally don't change this\ntemplate_folder = \"/home/user/.pymaker/template\"\nuse_default_template = true\nuse_git = true\ncreate_remote = true\n

If this file does not exist, it will be created on first run. The app will ask for the values of author_name, author_email, default_license and github_username. For author_name and author_email it will try to use the current global git user name and email if they are set as defaults, though the user can override these.

"},{"location":"configuration/#configuration-options","title":"Configuration options","text":"

The following options are available for configuring Py-Maker:

All of the boolean options are set to true by default. The template_folder is set to the default template folder, which is ~/.pymaker/template. The schema_version is for internal use, and should not be changed by the user.

"},{"location":"configuration/#view-configuration","title":"View configuration","text":"

You can list the current configuration with the command:

$ pymaker config show\n
"},{"location":"configuration/#edit-the-configuration-file","title":"Edit the configuration file","text":"

You can edit the configuration file with the command:

$ pymaker config edit\n

This will open the configuration file in your default editor. Under linux it will try to use xdg-open to open the file, and if that fails, it will try to use a few different editors until it finds one that works. Under Windows and Mac it will try to use the default editor.

You may also edit the configuration file manually, by default it is stored in ~/.pymaker/config.toml.

"},{"location":"configuration/#set-configuration","title":"Set configuration","text":"

The configuration is set the first time you run the app, but you can change these defaults at any time using the command:

$ pymaker config change\n

The latter command will prompt you for the values of Author name, Author Email, Default License and GitHub Username, then update the configuration file.

"},{"location":"configuration/#add-a-github-personal-access-token","title":"Add a GitHub Personal Access Token","text":"

This app is able to create a new GitHub repository for you. To do this, it will need a GitHub Personal Access Token. You can create a new token by going to GitHub Personal Access Tokens and clicking on the \"Generate new token\" button. Use the 'Classic' token option unless you really need more control. Unless you want to use the token on Private repositories, you should check the public_repo option and leave all the other permissions unchecked (this tool does not yet have the option to create a private repository). Give it a name (for your reference only) and chose an expiry date. You can choose never to expire, but this is not recommended. Once you have created the token, copy it (it will only be shown once, so make sure you copy it now). Then run the command:

$ pymaker config token\n

This will accept the token and store it in the configuration file. You can change the token at any time by running the same command again.

NEVER PUSH THE CONFIG FILE TO A REPOSITORY!!!

This shouldnt ever happen since the file is stored in the user's home directory, but it is worth mentioning. If you didn't choose any extra permissions, then the worst that can happen is that someone can use your token to create a new repository. This token is READ-ONLY, so it can't be used to do anything malicious, but it is still a good idea to keep it secret.

"},{"location":"configuration/#manually-editing-the-configuration-file","title":"Manually editing the configuration file","text":"

The configuration file is stored in TOML format, and can be edited manually if you wish. The file is stored in ~/.pymaker/config.toml by default. The configuration file is created on first run, so if you have not run the app yet, you will need to create the file manually.

"},{"location":"contributing/","title":"Contributing","text":""},{"location":"contributing/#contributing-to-py-maker","title":"Contributing to Py-Maker","text":"

Thank you for your interest in contributing to Py-Maker! We welcome all contributions, big or small.

If you are not sure where to start, please take a look at the open issues. If you have an idea for a new feature or would like to report a bug, please open a new issue. You can also check the TODO List for ideas.

I also welcome contributions to the documentation. If you find any errors or would like to suggest improvements, please open a new issue or submit a Pull Request.

I you would like to contribute to the code, but find the requirements below a bit daunting, please feel free to open a discussion and I can help you get started, or even pair on a PR.

"},{"location":"contributing/#prerequisites","title":"Prerequisites","text":"

Since this is a Python project, you will need to have Python installed on your machine. You can download the latest version of Python from the official website or using your Operating system's package manager. This project requires Python 3.9 or higher.

I'd recommend using pyenv to manage your Python installations, the pyenv-installer works for Linux and Mac OS X. For Windows, you can use the pyenv-win port. See here for installation instructions.

We also use Poetry to manage our dependencies. You should have this installed as well. You can install Poetry by following the instructions on the Poetry website.

"},{"location":"contributing/#getting-started","title":"Getting Started","text":"

Before you start contributing, please make sure you have read and understood our Code of Conduct and License.

To get started, follow these steps:

  1. Fork the repository and clone it to your local machine.
  2. Install the required dependencies (see next section).
  3. Create a new branch for your changes: git checkout -b my-new-feature.
  4. Make your changes and commit them: git commit -am 'Add some feature'.
  5. Push your changes to your fork: git push origin my-new-feature.
  6. Create a new pull request.
"},{"location":"contributing/#install-dependencies","title":"Install Dependencies","text":"

Run the following command to install the required dependencies:

$ poetry install\n

You then need to activate the virtual environment:

$ poetry shell\n

From here you can start working on the project. If you are using an IDE such as VSCode or PyCharm, you can set the use their Python interpreter setting to use the virtual environment that has just been created.

"},{"location":"contributing/#using-pip","title":"Using Pip","text":"

If you prefer to use pip instead of poetry, you can install the dependencies using the auto-generated requirements-dev.txt file:

$ pip install -r requirements-dev.txt\n

However, Poetry is the recommended (and only supported) way of developing this project and is tightly integrated with the code and tools.

"},{"location":"contributing/#linting","title":"Linting","text":"

I am quite strict about linting and code formatting and have set up a number of pre-commit hooks and tasks to ensure that the code meets the required standards.

Use the poe ruff, poe format and poe mypy tasks regularly. If you use VSCode, install the Ruff andMyPy extensions and set them to run on save. The included .vscode folder has the settings for this.

"},{"location":"contributing/#install-git-pre-commit-hooks","title":"Install Git Pre-Commit hooks","text":"

Please install this if you are intending to contribute to the project. It will check commits locally before they are pushed up to the Repo. The GitHub CI runs the linting checks (and in future probably MyPy as well), and will fail if there are any errors.

$ pre-commit install\npre-commit installed at .git/hooks/pre-commit\n

This will ensure that all code meets the required linting standard before being committed.

"},{"location":"contributing/#run-pre-commit-manually","title":"Run pre-commit manually","text":"

You can run these checks manually on all staged files using the below command :

poe pre\n
"},{"location":"contributing/#testing","title":"Testing","text":"

We are using pytest for testing.

At the moment the test framework is set up but we only have about 50% coverage. We will be adding more tests as we go along - and most definitely welcome any contributions to this area!

If you add any new features, please add tests for them. This will help us to ensure that the code is working as expected and will prevent any regressions. Currently we are not enforcing this until we have better coverage of the code - however if you break any existing tests, the CI will fail.

There is a task set up to run tests:

$ poe test\n

And run a watcher to automatically re-run the tests when files change:

$ poe test:watch\n

You can also run the tests manually using the following command:

$ pytest\n

The task is set up so we can automatically add other options in the future.

"},{"location":"contributing/#changelog","title":"Changelog","text":"

The changelog is automatically generated, using this project, so please do not edit it manually.

For maintainers, there is a POE task that will run this and update the changelog file.

$ poe changelog\n

You would also need to add a GitHub Personal Access Token to a local config file as usual. See the section in the Documentation for information.

However, you should NOT include a change to the CHANGELOG.md file in any Pull Requests. This will be handled by the maintainers when a new release is made. Your GitHub username will be added to the changelog automatically beside your PR.

"},{"location":"contributing/#convenience-tasks","title":"Convenience Tasks","text":"

There are a few other convenience tasks that can be run using the poe command. These are defined in the pyproject.toml file.

Each of these tasks can have extra options added which will be passed to the underlying tool.

Run mypy on the code base in strict mode:

$ poe mypy\n

Format the code using ruff format:

$ poe format\n

Lint the code using ruff:

$ poe ruff\n

Check the Markdown:

$ poe markdown\n

Run ruff, mypy and format at the same time:

$ poe lint\n
"},{"location":"contributing/#documentation-tasks","title":"Documentation Tasks","text":"

These are to help with developing and updating the documentation.

"},{"location":"contributing/#guidelines","title":"Guidelines","text":"

Here are some guidelines to follow when contributing to github-changelog-md:

If you are using VSCode, there is a config file in the .vscode folder that will help you to follow these guidelines. You may need to install some extensions to get the most out of it. I'll add a list of recommended extensions here soon. The Python, MyPy and Ruff ones are very helpful (the included .vscode folder helps configure these).

"},{"location":"contributing/#contact","title":"Contact","text":"

If you have any questions or need help with contributing, please contact me @seapagan on GitHub. You can also use the GitHub Discussions feature.

Happy contributing!

"},{"location":"future-plans/","title":"Future Plans","text":""},{"location":"future-plans/#future-plans","title":"Future Plans","text":"

The below is a list of things I'd like to add to the project in the future, and is kinda a 'work list' for me.

Everything below will be implemented and are in no particular order or importance.

"},{"location":"future-plans/#general","title":"General","text":""},{"location":"future-plans/#bugs","title":"Bugs","text":""},{"location":"future-plans/#back-burner","title":"Back Burner","text":"

These are ideas that I may or may not implement. They are here for reference.

"},{"location":"future-plans/#refactoring-code-cleanup","title":"Refactoring / Code Cleanup","text":""},{"location":"future-plans/#documentation","title":"Documentation","text":""},{"location":"future-plans/#testing","title":"Testing","text":""},{"location":"installation/","title":"Installation","text":"

It is best to install this package globally, rather than in a virtual environment, as it is intended to be used to create new projects. Since we are using Poetry to manage the dependencies, a virtual environment will be created for you anyway specific to each project you are creating.

"},{"location":"installation/#release-version","title":"Release Version","text":"

Install the package globally using pip:

$ pip install pyproject-maker\n

If you cannot install globally due to permissions, you can install it to your user install directory:

$ pip install --user pyproject-maker\n

or use pipx (recommended method)

$ pipx install pyproject-maker\n
"},{"location":"installation/#bleeding-edge-version","title":"Bleeding Edge Version","text":"

It is possible to install the latest development version of the package directly from the repository. In most cases this should be safe to do, but it is possible that the development version may not be stable or have bugs. If you are having issues with the development version, please open an issue on the repository.

Use pipx (recommended method):

$ pipx install git+https://github.com/seapagan/py-maker\n

Using pip:

$ pip install git+https://github.com/seapagan/py-maker\n

You can also use the --user flag for pip if you do not have permissions to install globally. This is NOT needed for pipx.

Lastly, you can clone the repository and install from the local copy:

$ git clone https://github.com/seapagan/py-maker\n$ cd py-maker\n$ pip install .\n
"},{"location":"license/","title":"License","text":"

MIT License

Copyright (c) 2023 Grant Ramsay

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

"},{"location":"tasks/","title":"Task Runner","text":"

The task-runner Poe the Poet is installed in the new project as a development dependency which allows us to run simple tasks (similar to npm or yarn scripts).

These are run (from within the virtual environment) using the poe command and then the script name, for example:

$ poe pre\n

To get a list of all available tasks with a description, run:

$ poe\n

You can define your own, but there are currently several specific ones provided in the new project:

If you selected to install MkDocs with this project, then there are some extra tasks to help with that:

There is also a task to run the tests if they were selected:

$ poe test\n

And run a watcher to automatically re-run the tests when files change:

$ poe test:watch\n

Finally, you can automatically generate your CHANGELOG.md file using:

$ poe changelog\n

The changelog uses my Markdown Changelog Generator tool to generate the changelog, check the documentation for that tool for more information.

These tasks are all defined in the pyproject.toml file in the [tool.poe.tasks] section. Take a look at this file if you want to add or remove tasks.

"},{"location":"usage/","title":"Using PyMaker","text":""},{"location":"usage/#create-a-new-project","title":"Create a new project","text":"

To create a new project, run the following command:

$ pymaker new <project-folder>\n

This will create a new directory with the name you provide.

You can create a new project in the current directory by using . as the project folder name. This must be an empty directory:

$ mkdir test-project\n$ cd test-project\n$ pymaker new .\n

The App will then run the steps needed to get you started quickly:

  1. Copy the template files into the new directory
  2. Initialise a git repository
  3. Commit the boilerplate to Git

You will be asked a series of questions to customise the new project.

"},{"location":"usage/#choose-a-package-name-and-description","title":"Choose a package name and description","text":"

When it asks \"Package Name?\" you can choose two variants :

  1. If you are creating a standard Python package that can optionally be uploaded to PyPI, enter a package name here. Note that underscores (\"_\") must be used as opposed to dashes (\"-\") to comply with Python package naming rules. Default is the project folder name with underscores replacing dashes, spaces or dots.
  2. For a stand-alone tool that will not be uploaded to PyPI, or is not a library, enter '-' for the package name. In this case the main.py will just be placed in the project root and no package folder will be created or referenced. You can also specify --standalone on the command line to skip this question.

For option 1 above, the App will check if the package name is available on PyPI or if it has already been used. In the latter case, you will be asked to choose another name.

"},{"location":"usage/#command-line-options","title":"Command line options","text":"

There are a few command line options that can be used to customise the build. Command line options override any settings in the config file.

For example, if use_git = false is set in the config file, then passing --git on the command line will override this and initialise a Git repository.

"},{"location":"usage/#-y-or-yes","title":"-y or --yes","text":"

Accept all defaults and do not ask any questions.

"},{"location":"usage/#-git-no-git","title":"--git / --no-git","text":"

Initialise a Git repository. Default is True unless use_git = false is set in the config file or --no-git is passed on the command line.

"},{"location":"usage/#-test-no-test","title":"--test / --no-test","text":"

Create a test directory and add the pytest dependency plus a few related plugins to the pyproject.toml file. Default is True unless include_testing = false is set in the config file or --no-test is passed on the command line.

"},{"location":"usage/#-lint-no-lint","title":"--lint / --no-lint","text":"

Add linting dependencies and configuration to the pyproject.toml file. Default is True unless include_linters = false is set in the config file or --no-lint is passed on the command line.

"},{"location":"usage/#-docs-no-docs","title":"--docs / --no-docs","text":"

Add MkDocs and some plugins to the pyproject.toml file. Default is True unless include_mkdocs = false is set in the config file or --no-docs is passed on the command line.

If you choose to run poetry automatically, this will also add a customized mkdocs.yml file and create a new default MkDocs site in the docs folder. Some useful plugins are also installed and added to the mkdocs.yml file.

"},{"location":"usage/#-github-no-github","title":"--github / --no-github","text":"

Create a GitHub repository and push the initial commit. Default is True unless create_remote = false is set in the config file or --no-github is passed on the command line. This option needs a GitHub Personal Access Token to be set in the config file, see here

"},{"location":"usage/#-standalone","title":"--standalone","text":"

Generate a stand-alone script instead of a package. This will place the main.py file in the project root and not create a package folder. This is useful for creating a single script that can be run from the command line. this is equivalent to entering - for the package name.

"},{"location":"usage/#-bare","title":"--bare","text":"

Generate a project without Testing, linting or documentation libraries and configurations. It will also NOT initialise a Git repository. Currently there is no config file option to do this automatically, you must use the command line option.

"},{"location":"usage/#run-poetry-install-automatically","title":"Run poetry install automatically","text":"

You will be asked if you want to run poetry install automatically. This will create a virtual environment and install the dependencies, plus also create a bare MkDocs site and configuration. This is the recommended option.

You will still need to run poetry shell to activate the virtual environment from inside the new project folder.

"},{"location":"usage/#start-developing","title":"Start developing","text":"

You should now change into the new directory, install dependencies and activate the virtual environment:

$ cd <project-folder>\n$ poetry install # if not done automatically already\n$ poetry shell\n

Now, you can start developing

"},{"location":"usage/#example-run","title":"Example run","text":"
$ pymaker new secret-docs\nPyMaker - Generate a Python project skeleton.\n\nCreating a new project at /home/bathroom/secret-docs\n\nName of the Application? (Secret Docs):\nPackage Name? (Use '-' for standalone script) (secret_docs):\nDescription of the Application?: Store all the Bigly amount of secret documents\nI have in the bathroom\n\nAuthor Name? (): Orange Tango\nAuthor Email? (): bigly@spraytan.org\nApplication License? [None/Apache2/BSD3/BSD2/GPL2/GPL3/LGPL/MIT/MPL2/CDDL/EPL2] (MIT):\n\nCreating a New Python app with the below settings :\n\n    Description : Store all the Bigly amount of secret documents I have in the\n                  bathroom\n   Package Name : secret_docs\n         Author : Orange Tango\n          Email : bigly@straytan.org\n        License : MIT\n    Project Dir : /home/bathroom/secret-docs\n           Name : Secret Docs\n     Standalone : False\n\nIs this correct? [y/n] (y):\n\n--> Creating project folder ... Done\n\nShould I Run 'poetry install' now? [y/n] (y):\nCreating virtualenv secret-docs in /home/bathroom/secret-docs/.venv\nUpdating dependencies\nResolving dependencies... (11.6s)\n\nPackage operations: 103 installs, 1 update, 0 removals\n\n  \u2022 Installing lazy-object-proxy (1.9.0)\n  \u2022 Installing six (1.16.0)\n\n            <snippy snip>\n\n  \u2022 Installing pytest-xdist (3.3.1)\n  \u2022 Installing tryceratops (2.3.2)\n\nWriting lock file\n\nInstalling the current project: secret-docs (0.1.0)\n\n--> Creating MkDocs project\nINFO    -  Writing config file: ./mkdocs.yml\nINFO    -  Writing initial docs: ./docs/index.md\n\n--> Creating Git repository ... Done\n\n--> Project created successfully.\n\nNext steps:\n\n1. Change to the project directory:\n2. Install the dependencies if not done above (creates a virtual environment):\n  $ poetry install\n3. Activate the virtual environment:\n  $ poetry shell\n4. Run the application:\n  $ secret-docs\n5. Code!\n\nSee the README.md file for more information.\n
"},{"location":"template/internal/","title":"The Internal Template","text":"

By default, the generated application will have a basic template that you can use to get started, this template is stored inside the package itself. It will contain all you need to get started, including a basic README.md file.

The dependency management is handled by Poetry, and we include a pyproject.toml file with several useful dependencies:

The pyproject.toml contains a useable configuration for all of these tools, but you can modify it to suit your needs.

It also contains several tasks for running the tests, linting, formatting and more. These use the Poe The Poet Poetry extension see Task Runner for more information.

"},{"location":"template/modify/","title":"Adding or Modifying files in the template","text":"

If you wish to add or change specific files in the template, you can do so by adding them to the ~/.pymaker/template folder. The files (and folders) in this folder will be copied to the root of the project when the template is generated.

Files in this global template folder will override any files in the default template, so you can for example change the README.md file, add to the .gitignore or even add a complete extra folder structure.

If you want to do a major change to the template, you can actually dump the default template to this folder and modify or delete files as you see fit. See the next section for more information on how to do this.

"},{"location":"template/replace/","title":"Replacing the Default Template","text":""},{"location":"template/replace/#dump-the-default-template","title":"Dump the Default Template","text":"

Should you wish to heavily modify the default template, or even replace it completely, you can do so by dumping the default template to the ~/.pymaker/template folder. This will copy all files from the default template to the global template folder, where you can modify or delete them as you see fit.

To do this, run the following command:

$ pymaker template dump\n

This will copy the default template to the global template folder (~/.pymaker/template). You can then modify or delete files as you see fit.

Running this command will ask you if you wish to set this exported template as the default template. It will then ask you if you want to disable the internal template. If you answer yes, then the internal template will be disabled, and ONLY the exported template will be used instead. Otherwise, both will still be used with the exported template taking precedence.

"},{"location":"template/replace/#change-the-location-of-the-template-folder","title":"Change the location of the Template folder","text":"

If you wish to change the location of the template folder, you can do so in 2 ways:

  1. By adding the --local flag to the above command (e.g. pymaker template dump --local). This will dump the default template to the current folder, giving you the option to disable the default template if needed. Note that any files in the folder will be overwritten.
  2. By changing to the folder containing your template and running pymaker template set. This will set the current folder as the template folder and give you the same option to disable the default template.

You can reset the template location back to the default ~/.pymaker/template folder by running the following command:

$ pymaker template reset\n
"},{"location":"template/replace/#choose-to-use-the-default-template-or-not","title":"Choose to use the Default Template or not","text":"

Running the dump command will give you the option to disable the default template completely and ONLY use the exported (or custom) template. You can also do this (or revert back to the default template) by running the following command:

$ pymaker template default <enable|disable>\n

enable will enable the default template, and disable will disable it. Please note that any custom templates you have created will be used regardless, and will overwrite the default template (if enabled) if they have the same file name.

"}]} \ No newline at end of file +{"config":{"lang":["en"],"separator":"[\\s\\-]+","pipeline":["stopWordFilter"]},"docs":[{"location":"","title":"Python Project Generation Tool","text":"

A fully customizable Python application to bootstrap Poetry-based boilerplate for you to start developing your Python applications quicker! Includes linting and Pytest libraries.

It will create a new directory for your project (or use the current directory), initialise a git repository, create a virtual environment, and install some basic dependencies for Testing, Linting and more. Optionally, it can also create a GitHub repository for you and push the initial commit.

Latest Version : v0.10.1

"},{"location":"#testing","title":"Testing","text":"

The generated project includes pytest and some related plugins to allow you to set up testing straight away.

Write your tests in the tests directory and run them with pytest.

"},{"location":"#linting","title":"Linting","text":"

The generated project includes Ruff for linting and code style formatting. Mypy is installed for type checking. These are set quite strictly by default, but you can edit the tools configuration in the pyproject.toml file.

"},{"location":"#customize-the-generated-project","title":"Customize the generated project","text":"

You can add extra or edited files to the generated project by adding them to the ~/.pymaker/template directory. The files in this directory will be copied into the generated project, overwriting any existing files with the same name.

It is also possible to dump the whole template into this folder or the current folder so full customization and even removal of files is possible.

"},{"location":"#pre-commit","title":"Pre-commit","text":"

The generated project uses pre-commit to run some checks on the code before it is committed. This is a great tool to help keep your code clean.

To install pre-commit, run the following command from inside your venv:

$ pre-commit install\npre-commit installed at .git/hooks/pre-commit\n
"},{"location":"#github-actions-and-configuration","title":"GitHub Actions and Configuration","text":"

By default the generated project includes a GitHub Actions workflow to run Dependabot to keep your dependencies up to date. There are also standard templates for Pull Request and Issues.

The plan is to add more workflows in the future, for example running tests and more.

"},{"location":"#changelog-generator","title":"Changelog Generator","text":"

Once you have at least one GitHub release, you can generate a CHANGELOG.md file automatically from this, using the included github-changelog-md tool.

You can run this manually by running the following command from inside your virtual environment:

$ poe changelog\n

You need to have a GitHub Personal Access Token set in the config file, see the instructions here for more information.

"},{"location":"#community-related-files","title":"Community related files","text":"

To aid in community building, the generated project includes a CODE_OF_CONDUCT.md file. This is based on the Contributor Covenant standard.

Future releases will include other Community related files (for example an AUTHORS file). There are also blank CONTRIBUTING.md and CHANGELOG.md files. The CHANGELOG.md file can be auto-generated.

"},{"location":"#contributing-to-this-project","title":"Contributing to this Project","text":"

For information on how to contribute to the project, see the CONTRIBUTING.md file in the root of the repository or on this website

"},{"location":"changelog/","title":"Changelog","text":""},{"location":"changelog/#changelog","title":"Changelog","text":"

This is an auto-generated log of all the changes that have been made to the project since the first release.

This project adheres to Semantic Versioning.

"},{"location":"changelog/#v0102-march-13-2024","title":"v0.10.2 (March 13, 2024)","text":"

Closed Issues

New Features

Bug Fixes

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v0101-march-12-2024","title":"v0.10.1 (March 12, 2024)","text":"

Closed Issues

Testing

Bug Fixes

Refactoring

Documentation

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v0100-march-06-2024","title":"v0.10.0 (March 06, 2024)","text":"

Closed Issues

Bug Fixes

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v095-march-04-2024","title":"v0.9.5 (March 04, 2024)","text":"

Closed Issues

Merged Pull Requests

New Features

Testing

Bug Fixes

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v094-december-11-2023","title":"v0.9.4 (December 11, 2023)","text":"

This is a security release that fixes a vulnerability in the 'cryptography' package.

Refactoring

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v093-october-29-2023","title":"v0.9.3 (October 29, 2023)","text":"

Refactoring

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v092-october-24-2023","title":"v0.9.2 (October 24, 2023)","text":"

Merged Pull Requests

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v091-october-12-2023","title":"v0.9.1 (October 12, 2023)","text":"

Bug Fixes

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v090-october-10-2023","title":"v0.9.0 (October 10, 2023)","text":"

Merged Pull Requests

New Features

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v080-october-04-2023","title":"v0.8.0 (October 04, 2023)","text":"

Merged Pull Requests

New Features

Refactoring

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v070-october-01-2023","title":"v0.7.0 (October 01, 2023)","text":"

Merged Pull Requests

New Features

Documentation

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v062-september-24-2023","title":"v0.6.2 (September 24, 2023)","text":"

Closed Issues

Merged Pull Requests

Bug Fixes

Full Changelog | Diff | Patch

"},{"location":"changelog/#v061-september-23-2023","title":"v0.6.1 (September 23, 2023)","text":"

Merged Pull Requests

Bug Fixes

Documentation

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v060-september-14-2023","title":"v0.6.0 (September 14, 2023)","text":"

New Features

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v051-september-12-2023","title":"v0.5.1 (September 12, 2023)","text":"

New Features

Bug Fixes

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v050-august-31-2023","title":"v0.5.0 (August 31, 2023)","text":"

New Features

Bug Fixes

Refactoring

Documentation

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v045-august-17-2023","title":"v0.4.5 (August 17, 2023)","text":"

New Features

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v044-august-15-2023","title":"v0.4.4 (August 15, 2023)","text":"

New Features

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v043-august-13-2023","title":"v0.4.3 (August 13, 2023)","text":"

New Features

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v042-august-10-2023","title":"v0.4.2 (August 10, 2023)","text":"

Full Changelog | Diff | Patch

"},{"location":"changelog/#v041-august-10-2023","title":"v0.4.1 (August 10, 2023)","text":"

Full Changelog | Diff | Patch

"},{"location":"changelog/#v040-august-10-2023","title":"v0.4.0 (August 10, 2023)","text":"

New Features

Refactoring

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v030-july-30-2023","title":"v0.3.0 (July 30, 2023)","text":"

New Features

Refactoring

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v021-july-26-2023","title":"v0.2.1 (July 26, 2023)","text":"

New Features

Documentation

Full Changelog | Diff | Patch

"},{"location":"changelog/#v020-july-26-2023","title":"v0.2.0 (July 26, 2023)","text":"

Refactoring

Dependency Updates

Full Changelog | Diff | Patch

"},{"location":"changelog/#v010-july-06-2023","title":"v0.1.0 (July 06, 2023)","text":"

Merged Pull Requests

New Features

Refactoring

This changelog was generated using github-changelog-md by Seapagan

"},{"location":"configuration/","title":"Configuration","text":""},{"location":"configuration/#configuration-file","title":"Configuration file","text":"

This app needs minimal configuration, most options default to True. The configuration is stored in a TOML file in a sub-folder of the user's home directory. By default (and currently the only option) this file is stored in ~/.pymaker/config.toml. An example of this file is:

[pymaker]\nauthor_email = \"user@server.com\"\nauthor_name = \"Python User\"\ndefault_license = \"MIT\"\ngithub_username = \"githubuser\" # optional\ngithub_token = \"ghp_1234567890abcdefghij\" # optional\ngithub_protocol = \"ssh\"\ninclude_linters = true\ninclude_mkdocs = true\ninclude_testing = true\ninstall_pre_commit = true\nschema_version = \"1.0\" # for internal use, generally don't change this\ntemplate_folder = \"/home/user/.pymaker/template\"\nuse_default_template = true\nuse_git = true\ncreate_remote = true\n

If this file does not exist, it will be created on first run. The app will ask for the values of author_name, author_email, default_license and github_username. For author_name and author_email it will try to use the current global git user name and email if they are set as defaults, though the user can override these.

"},{"location":"configuration/#configuration-options","title":"Configuration options","text":"

The following options are available for configuring Py-Maker:

All of the boolean options are set to true by default. The template_folder is set to the default template folder, which is ~/.pymaker/template. The schema_version is for internal use, and should not be changed by the user.

"},{"location":"configuration/#view-configuration","title":"View configuration","text":"

You can list the current configuration with the command:

$ pymaker config show\n
"},{"location":"configuration/#edit-the-configuration-file","title":"Edit the configuration file","text":"

You can edit the configuration file with the command:

$ pymaker config edit\n

This will open the configuration file in your default editor. Under linux it will try to use xdg-open to open the file, and if that fails, it will try to use a few different editors until it finds one that works. Under Windows and Mac it will try to use the default editor.

You may also edit the configuration file manually, by default it is stored in ~/.pymaker/config.toml.

"},{"location":"configuration/#set-configuration","title":"Set configuration","text":"

The configuration is set the first time you run the app, but you can change these defaults at any time using the command:

$ pymaker config change\n

The latter command will prompt you for the values of Author name, Author Email, Default License and GitHub Username, then update the configuration file.

"},{"location":"configuration/#add-a-github-personal-access-token","title":"Add a GitHub Personal Access Token","text":"

This app is able to create a new GitHub repository for you. To do this, it will need a GitHub Personal Access Token. You can create a new token by going to GitHub Personal Access Tokens and clicking on the \"Generate new token\" button. Use the 'Classic' token option unless you really need more control. Unless you want to use the token on Private repositories, you should check the public_repo option and leave all the other permissions unchecked (this tool does not yet have the option to create a private repository). Give it a name (for your reference only) and chose an expiry date. You can choose never to expire, but this is not recommended. Once you have created the token, copy it (it will only be shown once, so make sure you copy it now). Then run the command:

$ pymaker config token\n

This will accept the token and store it in the configuration file. You can change the token at any time by running the same command again.

NEVER PUSH THE CONFIG FILE TO A REPOSITORY!!!

This shouldnt ever happen since the file is stored in the user's home directory, but it is worth mentioning. If you didn't choose any extra permissions, then the worst that can happen is that someone can use your token to create a new repository. This token is READ-ONLY, so it can't be used to do anything malicious, but it is still a good idea to keep it secret.

"},{"location":"configuration/#manually-editing-the-configuration-file","title":"Manually editing the configuration file","text":"

The configuration file is stored in TOML format, and can be edited manually if you wish. The file is stored in ~/.pymaker/config.toml by default. The configuration file is created on first run, so if you have not run the app yet, you will need to create the file manually.

"},{"location":"contributing/","title":"Contributing","text":""},{"location":"contributing/#contributing-to-py-maker","title":"Contributing to Py-Maker","text":"

Thank you for your interest in contributing to Py-Maker! We welcome all contributions, big or small.

If you are not sure where to start, please take a look at the open issues. If you have an idea for a new feature or would like to report a bug, please open a new issue. You can also check the TODO List for ideas.

I also welcome contributions to the documentation. If you find any errors or would like to suggest improvements, please open a new issue or submit a Pull Request.

I you would like to contribute to the code, but find the requirements below a bit daunting, please feel free to open a discussion and I can help you get started, or even pair on a PR.

"},{"location":"contributing/#prerequisites","title":"Prerequisites","text":"

Since this is a Python project, you will need to have Python installed on your machine. You can download the latest version of Python from the official website or using your Operating system's package manager. This project requires Python 3.9 or higher.

I'd recommend using pyenv to manage your Python installations, the pyenv-installer works for Linux and Mac OS X. For Windows, you can use the pyenv-win port. See here for installation instructions.

We also use Poetry to manage our dependencies. You should have this installed as well. You can install Poetry by following the instructions on the Poetry website.

"},{"location":"contributing/#getting-started","title":"Getting Started","text":"

Before you start contributing, please make sure you have read and understood our Code of Conduct and License.

To get started, follow these steps:

  1. Fork the repository and clone it to your local machine.
  2. Install the required dependencies (see next section).
  3. Create a new branch for your changes: git checkout -b my-new-feature.
  4. Make your changes and commit them: git commit -am 'Add some feature'.
  5. Push your changes to your fork: git push origin my-new-feature.
  6. Create a new pull request.
"},{"location":"contributing/#install-dependencies","title":"Install Dependencies","text":"

Run the following command to install the required dependencies:

$ poetry install\n

You then need to activate the virtual environment:

$ poetry shell\n

From here you can start working on the project. If you are using an IDE such as VSCode or PyCharm, you can set the use their Python interpreter setting to use the virtual environment that has just been created.

"},{"location":"contributing/#using-pip","title":"Using Pip","text":"

If you prefer to use pip instead of poetry, you can install the dependencies using the auto-generated requirements-dev.txt file:

$ pip install -r requirements-dev.txt\n

However, Poetry is the recommended (and only supported) way of developing this project and is tightly integrated with the code and tools.

"},{"location":"contributing/#linting","title":"Linting","text":"

I am quite strict about linting and code formatting and have set up a number of pre-commit hooks and tasks to ensure that the code meets the required standards.

Use the poe ruff, poe format and poe mypy tasks regularly. If you use VSCode, install the Ruff andMyPy extensions and set them to run on save. The included .vscode folder has the settings for this.

"},{"location":"contributing/#install-git-pre-commit-hooks","title":"Install Git Pre-Commit hooks","text":"

Please install this if you are intending to contribute to the project. It will check commits locally before they are pushed up to the Repo. The GitHub CI runs the linting checks (and in future probably MyPy as well), and will fail if there are any errors.

$ pre-commit install\npre-commit installed at .git/hooks/pre-commit\n

This will ensure that all code meets the required linting standard before being committed.

"},{"location":"contributing/#run-pre-commit-manually","title":"Run pre-commit manually","text":"

You can run these checks manually on all staged files using the below command :

poe pre\n
"},{"location":"contributing/#testing","title":"Testing","text":"

We are using pytest for testing.

At the moment the test framework is set up but we only have about 50% coverage. We will be adding more tests as we go along - and most definitely welcome any contributions to this area!

If you add any new features, please add tests for them. This will help us to ensure that the code is working as expected and will prevent any regressions. Currently we are not enforcing this until we have better coverage of the code - however if you break any existing tests, the CI will fail.

There is a task set up to run tests:

$ poe test\n

And run a watcher to automatically re-run the tests when files change:

$ poe test:watch\n

You can also run the tests manually using the following command:

$ pytest\n

The task is set up so we can automatically add other options in the future.

"},{"location":"contributing/#changelog","title":"Changelog","text":"

The changelog is automatically generated, using this project, so please do not edit it manually.

For maintainers, there is a POE task that will run this and update the changelog file.

$ poe changelog\n

You would also need to add a GitHub Personal Access Token to a local config file as usual. See the section in the Documentation for information.

However, you should NOT include a change to the CHANGELOG.md file in any Pull Requests. This will be handled by the maintainers when a new release is made. Your GitHub username will be added to the changelog automatically beside your PR.

"},{"location":"contributing/#convenience-tasks","title":"Convenience Tasks","text":"

There are a few other convenience tasks that can be run using the poe command. These are defined in the pyproject.toml file.

Each of these tasks can have extra options added which will be passed to the underlying tool.

Run mypy on the code base in strict mode:

$ poe mypy\n

Format the code using ruff format:

$ poe format\n

Lint the code using ruff:

$ poe ruff\n

Check the Markdown:

$ poe markdown\n

Run ruff, mypy and format at the same time:

$ poe lint\n
"},{"location":"contributing/#documentation-tasks","title":"Documentation Tasks","text":"

These are to help with developing and updating the documentation.

"},{"location":"contributing/#guidelines","title":"Guidelines","text":"

Here are some guidelines to follow when contributing to github-changelog-md:

If you are using VSCode, there is a config file in the .vscode folder that will help you to follow these guidelines. You may need to install some extensions to get the most out of it. I'll add a list of recommended extensions here soon. The Python, MyPy and Ruff ones are very helpful (the included .vscode folder helps configure these).

"},{"location":"contributing/#contact","title":"Contact","text":"

If you have any questions or need help with contributing, please contact me @seapagan on GitHub. You can also use the GitHub Discussions feature.

Happy contributing!

"},{"location":"future-plans/","title":"Future Plans","text":""},{"location":"future-plans/#future-plans","title":"Future Plans","text":"

The below is a list of things I'd like to add to the project in the future, and is kinda a 'work list' for me.

Everything below will be implemented and are in no particular order or importance.

"},{"location":"future-plans/#general","title":"General","text":""},{"location":"future-plans/#bugs","title":"Bugs","text":""},{"location":"future-plans/#back-burner","title":"Back Burner","text":"

These are ideas that I may or may not implement. They are here for reference.

"},{"location":"future-plans/#refactoring-code-cleanup","title":"Refactoring / Code Cleanup","text":""},{"location":"future-plans/#documentation","title":"Documentation","text":""},{"location":"future-plans/#testing","title":"Testing","text":""},{"location":"installation/","title":"Installation","text":"

It is best to install this package globally, rather than in a virtual environment, as it is intended to be used to create new projects. Since we are using Poetry to manage the dependencies, a virtual environment will be created for you anyway specific to each project you are creating.

"},{"location":"installation/#release-version","title":"Release Version","text":"

Install the package globally using pip:

$ pip install pyproject-maker\n

If you cannot install globally due to permissions, you can install it to your user install directory:

$ pip install --user pyproject-maker\n

or use pipx (recommended method)

$ pipx install pyproject-maker\n
"},{"location":"installation/#bleeding-edge-version","title":"Bleeding Edge Version","text":"

It is possible to install the latest development version of the package directly from the repository. In most cases this should be safe to do, but it is possible that the development version may not be stable or have bugs. If you are having issues with the development version, please open an issue on the repository.

Use pipx (recommended method):

$ pipx install git+https://github.com/seapagan/py-maker\n

Using pip:

$ pip install git+https://github.com/seapagan/py-maker\n

You can also use the --user flag for pip if you do not have permissions to install globally. This is NOT needed for pipx.

Lastly, you can clone the repository and install from the local copy:

$ git clone https://github.com/seapagan/py-maker\n$ cd py-maker\n$ pip install .\n
"},{"location":"license/","title":"License","text":"

MIT License

Copyright (c) 2023 Grant Ramsay

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

"},{"location":"tasks/","title":"Task Runner","text":"

The task-runner Poe the Poet is installed in the new project as a development dependency which allows us to run simple tasks (similar to npm or yarn scripts).

These are run (from within the virtual environment) using the poe command and then the script name, for example:

$ poe pre\n

To get a list of all available tasks with a description, run:

$ poe\n

You can define your own, but there are currently several specific ones provided in the new project:

If you selected to install MkDocs with this project, then there are some extra tasks to help with that:

There is also a task to run the tests if they were selected:

$ poe test\n

And run a watcher to automatically re-run the tests when files change:

$ poe test:watch\n

Finally, you can automatically generate your CHANGELOG.md file using:

$ poe changelog\n

The changelog uses my Markdown Changelog Generator tool to generate the changelog, check the documentation for that tool for more information.

These tasks are all defined in the pyproject.toml file in the [tool.poe.tasks] section. Take a look at this file if you want to add or remove tasks.

"},{"location":"usage/","title":"Using PyMaker","text":""},{"location":"usage/#create-a-new-project","title":"Create a new project","text":"

To create a new project, run the following command:

$ pymaker new <project-folder>\n

This will create a new directory with the name you provide.

You can create a new project in the current directory by using . as the project folder name. This must be an empty directory:

$ mkdir test-project\n$ cd test-project\n$ pymaker new .\n

The App will then run the steps needed to get you started quickly:

  1. Copy the template files into the new directory
  2. Initialise a git repository
  3. Commit the boilerplate to Git

You will be asked a series of questions to customise the new project.

"},{"location":"usage/#choose-a-package-name-and-description","title":"Choose a package name and description","text":"

When it asks \"Package Name?\" you can choose two variants :

  1. If you are creating a standard Python package that can optionally be uploaded to PyPI, enter a package name here. Note that underscores (\"_\") must be used as opposed to dashes (\"-\") to comply with Python package naming rules. Default is the project folder name with underscores replacing dashes, spaces or dots.
  2. For a stand-alone tool that will not be uploaded to PyPI, or is not a library, enter '-' for the package name. In this case the main.py will just be placed in the project root and no package folder will be created or referenced. You can also specify --standalone on the command line to skip this question.

For option 1 above, the App will check if the package name is available on PyPI or if it has already been used. In the latter case, you will be asked to choose another name.

"},{"location":"usage/#command-line-options","title":"Command line options","text":"

There are a few command line options that can be used to customise the build. Command line options override any settings in the config file.

For example, if use_git = false is set in the config file, then passing --git on the command line will override this and initialise a Git repository.

"},{"location":"usage/#-y-or-yes","title":"-y or --yes","text":"

Accept all defaults and do not ask any questions.

"},{"location":"usage/#-git-no-git","title":"--git / --no-git","text":"

Initialise a Git repository. Default is True unless use_git = false is set in the config file or --no-git is passed on the command line.

"},{"location":"usage/#-test-no-test","title":"--test / --no-test","text":"

Create a test directory and add the pytest dependency plus a few related plugins to the pyproject.toml file. Default is True unless include_testing = false is set in the config file or --no-test is passed on the command line.

"},{"location":"usage/#-lint-no-lint","title":"--lint / --no-lint","text":"

Add linting dependencies and configuration to the pyproject.toml file. Default is True unless include_linters = false is set in the config file or --no-lint is passed on the command line.

"},{"location":"usage/#-docs-no-docs","title":"--docs / --no-docs","text":"

Add MkDocs and some plugins to the pyproject.toml file. Default is True unless include_mkdocs = false is set in the config file or --no-docs is passed on the command line.

If you choose to run poetry automatically, this will also add a customized mkdocs.yml file and create a new default MkDocs site in the docs folder. Some useful plugins are also installed and added to the mkdocs.yml file.

"},{"location":"usage/#-github-no-github","title":"--github / --no-github","text":"

Create a GitHub repository and push the initial commit. Default is True unless create_remote = false is set in the config file or --no-github is passed on the command line. This option needs a GitHub Personal Access Token to be set in the config file, see here

"},{"location":"usage/#-standalone","title":"--standalone","text":"

Generate a stand-alone script instead of a package. This will place the main.py file in the project root and not create a package folder. This is useful for creating a single script that can be run from the command line. this is equivalent to entering - for the package name.

"},{"location":"usage/#-bare","title":"--bare","text":"

Generate a project without Testing, linting or documentation libraries and configurations. It will also NOT initialise a Git repository. Currently there is no config file option to do this automatically, you must use the command line option.

"},{"location":"usage/#run-poetry-install-automatically","title":"Run poetry install automatically","text":"

You will be asked if you want to run poetry install automatically. This will create a virtual environment and install the dependencies, plus also create a bare MkDocs site and configuration. This is the recommended option.

You will still need to run poetry shell to activate the virtual environment from inside the new project folder.

"},{"location":"usage/#start-developing","title":"Start developing","text":"

You should now change into the new directory, install dependencies and activate the virtual environment:

$ cd <project-folder>\n$ poetry install # if not done automatically already\n$ poetry shell\n

Now, you can start developing

"},{"location":"usage/#example-run","title":"Example run","text":"
$ pymaker new secret-docs\nPyMaker - Generate a Python project skeleton.\n\nCreating a new project at /home/bathroom/secret-docs\n\nName of the Application? (Secret Docs):\nPackage Name? (Use '-' for standalone script) (secret_docs):\nDescription of the Application?: Store all the Bigly amount of secret documents\nI have in the bathroom\n\nAuthor Name? (): Orange Tango\nAuthor Email? (): bigly@spraytan.org\nApplication License? [None/Apache2/BSD3/BSD2/GPL2/GPL3/LGPL/MIT/MPL2/CDDL/EPL2] (MIT):\n\nCreating a New Python app with the below settings :\n\n    Description : Store all the Bigly amount of secret documents I have in the\n                  bathroom\n   Package Name : secret_docs\n         Author : Orange Tango\n          Email : bigly@straytan.org\n        License : MIT\n    Project Dir : /home/bathroom/secret-docs\n           Name : Secret Docs\n     Standalone : False\n\nIs this correct? [y/n] (y):\n\n--> Creating project folder ... Done\n\nShould I Run 'poetry install' now? [y/n] (y):\nCreating virtualenv secret-docs in /home/bathroom/secret-docs/.venv\nUpdating dependencies\nResolving dependencies... (11.6s)\n\nPackage operations: 103 installs, 1 update, 0 removals\n\n  \u2022 Installing lazy-object-proxy (1.9.0)\n  \u2022 Installing six (1.16.0)\n\n            <snippy snip>\n\n  \u2022 Installing pytest-xdist (3.3.1)\n  \u2022 Installing tryceratops (2.3.2)\n\nWriting lock file\n\nInstalling the current project: secret-docs (0.1.0)\n\n--> Creating MkDocs project\nINFO    -  Writing config file: ./mkdocs.yml\nINFO    -  Writing initial docs: ./docs/index.md\n\n--> Creating Git repository ... Done\n\n--> Project created successfully.\n\nNext steps:\n\n1. Change to the project directory:\n2. Install the dependencies if not done above (creates a virtual environment):\n  $ poetry install\n3. Activate the virtual environment:\n  $ poetry shell\n4. Run the application:\n  $ secret-docs\n5. Code!\n\nSee the README.md file for more information.\n
"},{"location":"template/internal/","title":"The Internal Template","text":"

By default, the generated application will have a basic template that you can use to get started, this template is stored inside the package itself. It will contain all you need to get started, including a basic README.md file.

The dependency management is handled by Poetry, and we include a pyproject.toml file with several useful dependencies:

The pyproject.toml contains a useable configuration for all of these tools, but you can modify it to suit your needs.

It also contains several tasks for running the tests, linting, formatting and more. These use the Poe The Poet Poetry extension see Task Runner for more information.

"},{"location":"template/modify/","title":"Adding or Modifying files in the template","text":"

If you wish to add or change specific files in the template, you can do so by adding them to the ~/.pymaker/template folder. The files (and folders) in this folder will be copied to the root of the project when the template is generated.

Files in this global template folder will override any files in the default template, so you can for example change the README.md file, add to the .gitignore or even add a complete extra folder structure.

If you want to do a major change to the template, you can actually dump the default template to this folder and modify or delete files as you see fit. See the next section for more information on how to do this.

"},{"location":"template/replace/","title":"Replacing the Default Template","text":""},{"location":"template/replace/#dump-the-default-template","title":"Dump the Default Template","text":"

Should you wish to heavily modify the default template, or even replace it completely, you can do so by dumping the default template to the ~/.pymaker/template folder. This will copy all files from the default template to the global template folder, where you can modify or delete them as you see fit.

To do this, run the following command:

$ pymaker template dump\n

This will copy the default template to the global template folder (~/.pymaker/template). You can then modify or delete files as you see fit.

Running this command will ask you if you wish to set this exported template as the default template. It will then ask you if you want to disable the internal template. If you answer yes, then the internal template will be disabled, and ONLY the exported template will be used instead. Otherwise, both will still be used with the exported template taking precedence.

"},{"location":"template/replace/#change-the-location-of-the-template-folder","title":"Change the location of the Template folder","text":"

If you wish to change the location of the template folder, you can do so in 2 ways:

  1. By adding the --local flag to the above command (e.g. pymaker template dump --local). This will dump the default template to the current folder, giving you the option to disable the default template if needed. Note that any files in the folder will be overwritten.
  2. By changing to the folder containing your template and running pymaker template set. This will set the current folder as the template folder and give you the same option to disable the default template.

You can reset the template location back to the default ~/.pymaker/template folder by running the following command:

$ pymaker template reset\n
"},{"location":"template/replace/#choose-to-use-the-default-template-or-not","title":"Choose to use the Default Template or not","text":"

Running the dump command will give you the option to disable the default template completely and ONLY use the exported (or custom) template. You can also do this (or revert back to the default template) by running the following command:

$ pymaker template default <enable|disable>\n

enable will enable the default template, and disable will disable it. Please note that any custom templates you have created will be used regardless, and will overwrite the default template (if enabled) if they have the same file name.

"}]} \ No newline at end of file diff --git a/sitemap.xml.gz b/sitemap.xml.gz index 659f182b..d2e74572 100644 Binary files a/sitemap.xml.gz and b/sitemap.xml.gz differ