diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS new file mode 100644 index 0000000..e3fd256 --- /dev/null +++ b/.github/CODEOWNERS @@ -0,0 +1 @@ +* @bandantonio diff --git a/.github/CODE_OF_CONDUCT.md b/.github/CODE_OF_CONDUCT.md new file mode 100644 index 0000000..42c1e0d --- /dev/null +++ b/.github/CODE_OF_CONDUCT.md @@ -0,0 +1,26 @@ +# Code of Conduct + +## Pledge + +We as members, contributors, and leaders pledge to make participation in this community a harassment-free experience for everyone, regardless of age, body size, visible or invisible disability, ethnicity, sex characteristics, gender identity and expression, level of experience, education, socio-economic status, nationality, personal appearance, race, religion, or sexual identity and orientation. + +We pledge to act and interact in ways that contribute to an open, welcoming, diverse, inclusive, and healthy community. + +## Standards + +βœ… Examples of behavior that contributes to a positive environment for our community include: + +* Demonstrating empathy and kindness toward other people +* Being respectful of differing opinions, viewpoints, and experiences +* Giving and gracefully accepting constructive feedback +* Accepting responsibility and apologizing to those affected by our mistakes, and learning from the experience +* Focusing on what is best not just for us as individuals, but for the overall community + +❌ Examples of unacceptable behavior include: + +* The use of sexualized language or imagery, and sexual attention or advances of any kind +* Trolling, insulting or derogatory comments, and personal or political attacks +* Public or private harassment +* Publishing others' private information, such as a physical or email address, without their explicit permission +* Contacting individual members, contributors, or leaders privately, outside designated community mechanisms, without their explicit permission +* Other conduct which could reasonably be considered inappropriate in a professional setting diff --git a/.github/CONTRIBUTING.md b/.github/CONTRIBUTING.md new file mode 100644 index 0000000..2d5bff9 --- /dev/null +++ b/.github/CONTRIBUTING.md @@ -0,0 +1,96 @@ +# Contributing Guide + +Thank you for investing your time in contributing to the project! I, as the code owner, really appreciates it! 🩷 + +First, read theΒ [Code of Conduct](./CODE_OF_CONDUCT.md)Β to keep our community approachable and respectable. + +## How Can I Contribute? + +### πŸ› Reporting Bugs + +If you spot a problem with the plugin, [search if an issue already exists][issue-bug]. If a related issue doesn't exist, you can open a new issue using the corresponding bug report form. Please provide as much information as possible (including screenshots and error messages) about the issue and how to reproduce it. + +### πŸ› οΈ Resolving Issues + +Scan through the [existing issues][issue-bug] to find one that interests you. As a general rule, issues are not assigned to anyone. If you find an issue to work on, you are welcome to open a PR with a fix. + +### πŸ’‘ Suggesting Enhancements + +If you have an idea to improve the plugin, [search if someone else has already suggested it][issue-enhancement]. If a related issue doesn't exist, you can open a new issue using the corresponding enhancement request form. Please provide as much detail as possible about your suggestion. + +### πŸ“š Updating Documentation + +If you've found something in the documentation that should be updated, [search open issues][issue-doc] to see if someone else has reported the same thing. If it's something new, open an issue using the corresponding template. Issues are used to have a conversation about the problem you want to fix. If you want to fix it yourself, you are welcome to proceed with a PR. + +[issue-bug]: https://github.com/bandantonio/obsidian-apple-books-highlights-plugin/issues?q=is%3Aopen+is%3Aissue+label%3Abug +[issue-enhancement]: https://github.com/bandantonio/obsidian-apple-books-highlights-plugin/issues?q=is%3Aissue+is%3Aopen+label%3Aenhancement +[issue-doc]: https://github.com/bandantonio/obsidian-apple-books-highlights-plugin/issues?q=is%3Aopen+is%3Aissue+label%3Adocumentation + +## Getting Started + +### Issues + +Use the instructions in the section above to find an issue that you want to work on. + +### Make changes + +1. Fork the repository. +2. Create a new branch. Stick to the following naming convention: + + ``` + / + ``` + where `` is one of the following: + - `feat` + - `fix` + - `docs` + - `test` + - `chore` + - `refactor` + +3. Make your changes. + - If your changes are related to the plugin's functionality, make sure to write the required tests, and (yes!) make sure they pass. + +> [!IMPORTANT] +> Please, don't change the plugin's version either in the `manifest.json` or `package.json` files. This may lead to conflicts when merging your PR and disrupt the release process. The version will be updated by the code owner. + +## Commit changes + +Commit the changes once you are happy with them. Stick to the [Conventional Commits](https://www.conventionalcommits.org/en/v1.0.0/) specification when writing your commit messages: + +``` +: + + +``` + +You may want to check `git log` to see the commit history and get an idea of how to properly write your commit messages. + +> [!IMPORTANT] +> The repository uses git pre-commit hook to launch linter and tests before every commit. If the tests fail, the commit will be rejected. The only valid reason to skip the pre-commit check is when your changes only affect the README file. + +## Push changes + +Push the changes to your fork. + +## Pull request + +6. When you're finished with the changes, create a pull request (PR) to the `master` branch of the upstream repository. + - Don't forget to link PR to issue, if you are solving one. You can do this by adding `Fixes #` to the PR description. + - Enable the checkbox to allow maintainer edits so the branch can be updated for a merge. + - Once you submit your PR, the code owner will review your proposal. + - If you're the first-time contributor, your PR will require approval before the CI checks will be triggered. + - If not, the CI checks will be triggered automatically. + - During the review, please be ready to answer questions about your changes and provide additional information if needed. + - You may be asked for changes to be made before your PR can be merged, either using suggested changes or pull request comments. + - As you update your PR and apply changes, mark each conversation as resolved. + - After your changes are approved, you can merge your PR. + - Make sure to resolve all the conflicts before merging the PR. + +## Your PR is merged! + +Congratulations πŸŽ‰πŸŽ‰ The code owner thanks you ✨. + +Once your PR is merged, your contributions will eventually become a part of a new public release and will be available to the plugin's users. + +Happy to have you on board πŸš€ and waiting for your new contributions! diff --git a/.github/ISSUE_TEMPLATE/BUG-REPORT.yml b/.github/ISSUE_TEMPLATE/BUG-REPORT.yml new file mode 100644 index 0000000..39f06ae --- /dev/null +++ b/.github/ISSUE_TEMPLATE/BUG-REPORT.yml @@ -0,0 +1,85 @@ +name: Bug Report +description: If you encountered an error or faulty behavior +title: "[Bug]: " +labels: [ "bug" ] +body: + - type: markdown + attributes: + value: Thanks for taking the time to fill out this bug report! πŸ™ + - type: checkboxes + id: checklist + attributes: + label: Bug Report Checklist + description: Please check the following items before submitting your report. + options: + - label: I have searched the [existing issues](https://github.com/bandantonio/obsidian-apple-books-highlights-plugin/issues?q=is%3Aopen+is%3Aissue+label%3Abug) to avoid duplicates + required: true + - label: I have checked the plugin's [documentation](https://github.com/bandantonio/obsidian-apple-books-highlights-plugin/blob/master/README.md) + required: true + - type: input + id: plugin-version + attributes: + label: Plugin version + description: What version of the plugin are you using? + placeholder: 1.0.0 + validations: + required: true + - type: input + id: obsidian-version + attributes: + label: Obsidian version + description: What version of Obsidian are you using? + placeholder: 0.15.0 + validations: + required: true + - type: dropdown + id: macos-version + attributes: + label: macOS version + options: + - macOS Sequoia + - macOS Sonoma + - macOS Ventura + - macOS Monterey + default: 1 + validations: + required: true + - type: textarea + id: what-happened + attributes: + label: What happened? + description: Also, include screenshots, console output errors (if any), and any other related information. + placeholder: Please provide an explicit description of your issue, steps to reproduce, and what was the expected behavior. + validations: + required: true + - type: dropdown + id: behavior + attributes: + label: The issue occurs when + options: + - Importing a single book + - Importing all books + - In both cases + default: 1 + validations: + required: true + - type: dropdown + id: how-many-books + attributes: + label: How many books do you have in your Apple Books library? + description: An approximate number is fine. May help identify potential performance issues. + options: + - "20 or less" + - "21 - 50" + - "51 - 100" + - "100+" + validations: + required: true + - type: checkboxes + id: terms + attributes: + label: Code of Conduct + description: By submitting this issue, you agree to follow our [Code of Conduct](https://github.com/bandantonio/obsidian-apple-books-highlights-plugin/blob/master/.github/CODE_OF_CONDUCT.md) (make sure to open it in a new tab, if necessary). + options: + - label: I agree to follow this project's Code of Conduct + required: true diff --git a/.github/ISSUE_TEMPLATE/FEATURE-REQUEST.yml b/.github/ISSUE_TEMPLATE/FEATURE-REQUEST.yml new file mode 100644 index 0000000..59ac19d --- /dev/null +++ b/.github/ISSUE_TEMPLATE/FEATURE-REQUEST.yml @@ -0,0 +1,32 @@ +name: Feature Request +description: If you want to suggest an idea or a feature +title: "[Request]: " +labels: [ "enhancement", "question" ] +body: + - type: markdown + attributes: + value: Thanks for taking the time to fill out this request! πŸ™ + - type: checkboxes + id: checklist + attributes: + label: Feature Request Checklist + description: Please check the following items before submitting your request. + options: + - label: I have searched the [existing issues](https://github.com/bandantonio/obsidian-apple-books-highlights-plugin/issues?q=is%3Aopen+is%3Aissue+label%3Aenhancement%2Cquestion) to avoid duplicates + required: true + - type: textarea + id: feature + attributes: + label: What feature would you like to request? + description: Also include links to any relevant resources, examples, or similar implementations that you know or like. + placeholder: Please provide an explicit description of your request, and why you think it would be beneficial. + validations: + required: true + - type: checkboxes + id: terms + attributes: + label: Code of Conduct + description: By submitting this issue, you agree to follow our [Code of Conduct](https://github.com/bandantonio/obsidian-apple-books-highlights-plugin/blob/master/.github/CODE_OF_CONDUCT.md) (make sure to open it in a new tab, if necessary). + options: + - label: I agree to follow this project's Code of Conduct + required: true diff --git a/.github/ISSUE_TEMPLATE/bug-report.md b/.github/ISSUE_TEMPLATE/bug-report.md deleted file mode 100644 index d668b5f..0000000 --- a/.github/ISSUE_TEMPLATE/bug-report.md +++ /dev/null @@ -1,40 +0,0 @@ ---- -name: Bug report -about: Create a report to help improve the plugin -title: "[Bug] Error when ... " -labels: bug -assignees: bandantonio - ---- - -**Description the bug** -A clear and concise description of what the bug is. - -Also include the following details: -- Error behavior: intermittent/permanent. -- Error occurs when: - - [ ] Importing a single book - - [ ] Importing all books - - [ ] All the above -- Number of books and highlights (approximately) - -**General information** -- Plugin version: [e.g. 1.0.0] -- Obsidian version: [e.g. 0.15.0] -- MacOS version: [e.g. Sonoma] - -**To Reproduce** -Steps to reproduce the behavior: -1. Go to '...' -2. Click on '....' -3. ... -4. See error - -**Expected behavior** -A clear and concise description of what you expected to happen. - -**Screenshots** -If applicable, add screenshots to help explain your problem. - -**Additional context** -Add any other context about the problem here. diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml new file mode 100644 index 0000000..3ba13e0 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/config.yml @@ -0,0 +1 @@ +blank_issues_enabled: false diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md new file mode 100644 index 0000000..503387a --- /dev/null +++ b/.github/pull_request_template.md @@ -0,0 +1,18 @@ +# Description + + + + + + + +# Checklist + +- [ ] I accept the [Code of Conduct](https://github.com/bandantonio/obsidian-apple-books-highlights-plugin/blob/master/.github/CODE_OF_CONDUCT.md) +- [ ] I have performed a self-review of my code for consistency and potential leftover debug logs, commented out code, etc. +- [ ] I have added tests that prove that my feature works or that the fix is effective +- [ ] I have checked that new and existing unit tests pass locally with my changes +- [ ] I have updated the documentation accordingly (if necessary) +- [ ] I confirm that this PR DOESN'T change the plugin's version either in the `manifest.json` or `package.json` files +- [ ] I have checked that my commit messages are descriptive and follow the [Conventional Commits](https://www.conventionalcommits.org/en/v1.0.0/#summary) standard +- [ ] I have enabled the checkbox to allow maintainer edits so the branch can be updated for a merge.