-
Notifications
You must be signed in to change notification settings - Fork 0
fix(readme): reduce content to show project file tree with descriptions #10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,189 +1,15 @@ | ||
| # markdown-magic-transform-acknowledgements | ||
|
|
||
| <!-- doc-gen BADGES style=for-the-badge --> | ||
| [](https://www.npmjs.com/package/markdown-magic-transform-acknowledgements) [](https://www.npmjs.com/package/markdown-magic-transform-acknowledgements) [](https://www.npmjs.com/package/markdown-magic-transform-acknowledgements) [](https://github.com/ioncakephper/markdown-magic-transform-acknowledgements/actions) [](https://codecov.io/gh/ioncakephper/markdown-magic-transform-acknowledgements) [](https://github.com/ioncakephper/markdown-magic-transform-acknowledgements/releases) [](https://github.com/ioncakephper/markdown-magic-transform-acknowledgements/graphs/commit-activity) [](https://github.com/ioncakephper/markdown-magic-transform-acknowledgements/stargazers) [](https://github.com/ioncakephper/markdown-magic-transform-acknowledgements/network/members) [](https://github.com/ioncakephper/markdown-magic-transform-acknowledgements/watchers) [](https://github.com/ioncakephper/markdown-magic-transform-acknowledgements/commits) [](https://github.com/ioncakephper/markdown-magic-transform-acknowledgements/graphs/contributors) [](https://github.com/ioncakephper/markdown-magic-transform-acknowledgements/issues) [](https://github.com/ioncakephper/markdown-magic-transform-acknowledgements/pulls) [](https://github.com/ioncakephper/markdown-magic-transform-acknowledgements) [](https://github.com/ioncakephper/markdown-magic-transform-acknowledgements) [](https://github.com/ioncakephper/markdown-magic-transform-acknowledgements/search?l=) | ||
| <!-- end-doc-gen --> | ||
|
|
||
| A markdown-magic transform that automatically inserts an Acknowledgements section into your README, pulling from contributors, dependencies, or custom entries. | ||
|
|
||
| ## Install | ||
|
|
||
| ```bash | ||
| npm install --save-dev markdown-magic-transform-acknowledgements | ||
| ``` | ||
|
|
||
| ## Usage | ||
|
|
||
| ```js | ||
| // markdown.config.js | ||
| module.exports = { | ||
| transformDefaults: { | ||
| ACKNOWLEDGEMENTS: { | ||
| evaluateUsed: true, | ||
| includeDev: true, | ||
| highlightImportant: true, | ||
| }, | ||
| }, | ||
| transforms: { | ||
| ACKNOWLEDGEMENTS: require('markdown-magic-transform-acknowledgements'), | ||
| }, | ||
| }; | ||
| ``` | ||
|
|
||
| In your README.md | ||
|
|
||
| ```markdown | ||
| <!-- ACKNOWLEDGEMENTS --> | ||
| <!-- END_ACKNOWLEDGEMENTS --> | ||
| ``` | ||
|
|
||
| ## Example | ||
|
|
||
| README.md before: | ||
|
|
||
| ```markdown | ||
| <!-- ACKNOWLEDGEMENTS --> | ||
| <!-- END_ACKNOWLEDGEMENTS --> | ||
| ``` | ||
|
|
||
| README.md after: | ||
|
|
||
| ```markdown | ||
| <!-- ACKNOWLEDGEMENTS --> | ||
|
|
||
| - [@eslint/js](https://www.npmjs.com/package/%40eslint%2Fjs) — ESLint JavaScript language implementation | ||
| - [@eslint/markdown](https://www.npmjs.com/package/%40eslint%2Fmarkdown) — The official ESLint language plugin for Markdown | ||
| - [cross-spawn](https://www.npmjs.com/package/cross-spawn) — Cross platform child_process#spawn and child_process#spawnSync | ||
| - [eslint](https://www.npmjs.com/package/eslint) — An AST-based pattern checker for JavaScript. | ||
| - [eslint-plugin-json](https://www.npmjs.com/package/eslint-plugin-json) — eslint plugin for JSON files | ||
| - [eslint-plugin-yaml](https://www.npmjs.com/package/eslint-plugin-yaml) — Lint YAML files | ||
| - [fs](https://www.npmjs.com/package/fs) — No description available | ||
| - [jest](https://www.npmjs.com/package/jest) — Delightful JavaScript Testing. | ||
| - [jsonc-eslint-parser](https://www.npmjs.com/package/jsonc-eslint-parser) — JSON, JSONC and JSON5 parser for use with ESLint plugins | ||
| - [markdown-eslint-parser](https://www.npmjs.com/package/markdown-eslint-parser) — The ESLint custom parser for \*.md files. | ||
| - [markdown-magic](https://www.npmjs.com/package/markdown-magic) — Automatically update markdown files with content from external sources | ||
| - [markdown-magic-scripts](https://www.npmjs.com/package/markdown-magic-scripts) — Automatically generate a dynamic, customizable dashboard of your npm scripts in your README.md using this markdown-magic transform. Keep your project documentation in sync with your package.json. | ||
| - [markdown-magic-transform-badges](https://www.npmjs.com/package/markdown-magic-transform-badges) — No description available | ||
| - [path](https://www.npmjs.com/package/path) — Node.JS path module | ||
| - [prettier](https://www.npmjs.com/package/prettier) — Prettier is an opinionated code formatter | ||
| - [yaml-eslint-parser](https://www.npmjs.com/package/yaml-eslint-parser) — A YAML parser that produces output compatible with ESLint | ||
| <!-- END_ACKNOWLEDGEMENTS --> | ||
| ``` | ||
|
|
||
| ## Options | ||
|
|
||
| 1. **In the HTML comment:** | ||
| Options can be added as `key=value` or `"key"="value"` pairs | ||
|
|
||
| 2. **In `markdown-magic.config.js`:** You can provide default values for the | ||
| transform in the `transformDefaults` section of your `markdown-magic.config.js` | ||
| file. These defaults will be used unless overridden in the HTML comment. | ||
|
|
||
| | Option | Type | Default | Description | | ||
| | ------ | ---- | ------- | ----------- | | ||
| | `evaluatedUsed` | `boolean` | `false` | Scan repo files and include only used packages | | ||
| | `highlightImportant` | `boolean` | `false` | Mark important packages automatically (heuristic) | | ||
| | `includeDev` | `boolean` | `true` | Include devDependencies (can be overridden) | | ||
|
|
||
| ## Contributing | ||
|
|
||
| See [`CONTRIBUTING.md`](CONTRIBUTING.md) for details on how to raise issues, propose changes, and submit pull requests. In short: | ||
|
|
||
| - Open issues for bugs or feature requests with clear reproduction steps. | ||
| - For code contributions, fork the repo, create a branch, add tests, and open a PR against `main`. | ||
|
|
||
| ## License | ||
|
|
||
| This project is licensed under the terms of the MIT License. See the [`LICENSE`](LICENSE) file for details. | ||
|
|
||
| ## Acknowledgements | ||
|
|
||
| <!-- doc-gen ACKNOWLEDGEMENTS highlightImportant=true evaluateUsed=true includeDev=true --> | ||
| - [@eslint/js](https://www.npmjs.com/package/%40eslint%2Fjs) — ESLint JavaScript language implementation | ||
| - [@eslint/markdown](https://www.npmjs.com/package/%40eslint%2Fmarkdown) — The official ESLint language plugin for Markdown | ||
| - [cross-spawn](https://www.npmjs.com/package/cross-spawn) — Cross platform child_process#spawn and child_process#spawnSync | ||
| - 🌟 **[eslint](https://www.npmjs.com/package/eslint)** — **An AST-based pattern checker for JavaScript.** | ||
| - [eslint-plugin-json](https://www.npmjs.com/package/eslint-plugin-json) — eslint plugin for JSON files | ||
| - [eslint-plugin-yaml](https://www.npmjs.com/package/eslint-plugin-yaml) — Lint YAML files | ||
| - [fs](https://www.npmjs.com/package/fs) — No description available | ||
| - 🌟 **[jest](https://www.npmjs.com/package/jest)** — **Delightful JavaScript Testing.** | ||
| - [jsonc-eslint-parser](https://www.npmjs.com/package/jsonc-eslint-parser) — JSON, JSONC and JSON5 parser for use with ESLint plugins | ||
| - [markdown-eslint-parser](https://www.npmjs.com/package/markdown-eslint-parser) — The ESLint custom parser for *.md files. | ||
| - [markdown-magic](https://www.npmjs.com/package/markdown-magic) — Automatically update markdown files with content from external sources | ||
| - [markdown-magic-scripts](https://www.npmjs.com/package/markdown-magic-scripts) — Automatically generate a dynamic, customizable dashboard of your npm scripts in your README.md using this markdown-magic transform. Keep your project documentation in sync with your package.json. | ||
| - [markdown-magic-transform-badges](https://www.npmjs.com/package/markdown-magic-transform-badges) — No description available | ||
| - [markdown-magic-transform-treefile-extended](https://www.npmjs.com/package/markdown-magic-transform-treefile-extended) — A markdown-magic transform to generate a dynamic file tree in your markdown files. This extended version provides additional options for customizing the output. | ||
| - [path](https://www.npmjs.com/package/path) — Node.JS path module | ||
| - [prettier](https://www.npmjs.com/package/prettier) — Prettier is an opinionated code formatter | ||
| - [yaml-eslint-parser](https://www.npmjs.com/package/yaml-eslint-parser) — A YAML parser that produces output compatible with ESLint | ||
| <!-- end-doc-gen --> | ||
|
|
||
| ## Helper Scripts | ||
|
|
||
| <!-- doc-gen SCRIPTS format=list --> | ||
| - `docs` — Generate documentation by processing README.md with markdown-magic. (line [13](./package.json#L13)) | ||
|
|
||
| ```bash | ||
| npx markdown-magic README.md --config ./markdown-magic.config.js | ||
| ``` | ||
|
|
||
| - `fix` — Automatically fix linting issues and format codebase. (line [8](./package.json#L8)) | ||
|
|
||
| ```bash | ||
| npm run lint:fix && npm run format && npm run format:package | ||
| ``` | ||
|
|
||
| - `format` — Format all project files using Prettier. (line [9](./package.json#L9)) | ||
|
|
||
| ```bash | ||
| prettier --write . | ||
| ``` | ||
|
|
||
| - `format:package` — Format the package.json file using Prettier. (line [10](./package.json#L10)) | ||
|
|
||
| ```bash | ||
| prettier --write package.json | ||
| ``` | ||
|
|
||
| - `lint` — Lint all project files to ensure code quality and consistency. (line [11](./package.json#L11)) | ||
|
|
||
| ```bash | ||
| eslint . --ext .js,.json,.yaml,.yml,.md | ||
| ``` | ||
|
|
||
| - `lint:fix` — Lint all project files and automatically fix issues where possible. (line [12](./package.json#L12)) | ||
|
|
||
| ```bash | ||
| eslint . --ext .js,.json,.yaml,.yml,.md --fix | ||
| ``` | ||
|
|
||
| - `prep` — Prepare the project for publishing by generating docs and formatting code. (line [14](./package.json#L14)) | ||
|
|
||
| ```bash | ||
| npm run docs && npm run fix | ||
| ``` | ||
|
|
||
| - `test` — Run the test suite using Jest. (line [7](./package.json#L7)) | ||
|
|
||
| ```bash | ||
| jest --passWithNoTests | ||
| ``` | ||
| <!-- end-doc-gen --> | ||
|
|
||
| ## Project Structure | ||
|
|
||
| <!-- doc-gen treeFileExtended --> | ||
| <!-- doc-gen treeFileExtended showDescriptions --> | ||
| ``` | ||
| markdown-magic-transform-acknowledgements/ | ||
| ├── CHANGELOG.md | ||
| ├── CONTRIBUTING.md | ||
| ├── eslint.config.mjs | ||
| ├── index.js | ||
| ├── LICENSE | ||
| ├── markdown-magic.config.js | ||
| ├── package-lock.json | ||
| ├── package.json | ||
| ├── README.md | ||
| └── RULES_OF_CONDUCT.md | ||
| ├── CHANGELOG.md # A log or record of all notable changes made to the project. | ||
| ├── CONTRIBUTING.md # Guidelines for contributing to the project. | ||
| ├── eslint.config.mjs # Configuration file for ESLint, a static code analysis tool. | ||
| ├── index.js # The main entry point of the `markdown-magic-transform-acknowledgements` transform. | ||
| ├── LICENSE # The MIT License file for the project. | ||
| ├── markdown-magic.config.js # Configuration file for `markdown-magic`. | ||
| ├── package-lock.json # Records the exact version of each installed dependency. | ||
| ├── package.json # Contains metadata about the project and its dependencies. | ||
| ├── README.md # The main documentation file for the project. | ||
| └── RULES_OF_CONDUCT.md # Code of conduct for contributors. | ||
| ``` | ||
| <!-- end-doc-gen --> | ||
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This change removes essential information from the README, such as the project description, installation instructions, usage examples, and configuration options. While the new file tree with descriptions is a good improvement, removing all other content makes it very difficult for new users to understand what this project does or how to use it. The project's purpose (
markdown-magic-transform-acknowledgements) is no longer clear from the README. Please restore the deleted sections to provide complete documentation for the package, and integrate the new file tree into theProject Structuresection.