Skip to content
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

Implemented usage of custom package name in the generated package #128

Merged
merged 13 commits into from
Nov 9, 2022
Merged

Conversation

przemyslaw-zan
Copy link
Member

@przemyslaw-zan przemyslaw-zan commented Nov 2, 2022

Suggested merge commit message (convention)

Feature: The provided package name will now be used as a default name of a plugin (instead of MyPlugin) in the generated package. Closes #54.

Feature: Added the --plugin-name option that allows specifying the plugin name different from the package name. See #54.


Additional information

For example – encountered issues, assumptions you had to make, other affected tickets, etc.

Supported scopes

@pomek
Copy link
Member

pomek commented Nov 3, 2022

Something went wrong :(

image

node /Users/pomek/Projects/ckeditor/ckeditor5-package-generator/packages/ckeditor5-package-generator/bin/index.js @pomek/ckeditor5-example-package --dev --use-yarn --lang js
📍 Verifying the specified package name.
📍 Checking whether the "ckeditor5-example-package" directory can be created.
📍 Creating the directory "/Users/pomek/Projects/tmp/ckeditor5-example-package".
📍 Collecting the latest CKEditor 5 packages versions...
📍 Copying files...
📍 Installing dependencies... It takes a while.
📍 Initializing Git repository...
📍 Installing Git hooks...

Done!

Execute the "cd ckeditor5-example-package" command to change the current working directory
to the newly created package. Then, the package offers a few predefined scripts:

  * start - for creating the HTTP server with the editor sample,
  * test - for executing unit tests of an example plugin,
  * lint - for running a tool for static analyzing JavaScript files,
  * stylelint - for running a tool for static analyzing CSS files.

Example: yarn run start

 pomek@MBP-2020.local  ~/Projects/tmp  cd ckeditor5-example-package/
 pomek@MBP-2020.local  ~/.../tmp/ckeditor5-example-package   master (7a30f30)  yarn run start
yarn run v1.22.18
error Couldn't find a package.json file in "/Users/pomek/Projects/tmp/ckeditor5-example-package"
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

Copy link
Member

@pomek pomek left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I left a few comments.

Other than that, I guess the source files in the templates/ directory should no longer follow the .js and .ts extensions. I am fine with using *.txt, but we lose code highlighting. It does not work, though, as we have a lot of syntax errors right now.

README.md Outdated Show resolved Hide resolved
README.md Outdated Show resolved Hide resolved
Copy link
Member

@pomek pomek left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

@pomek pomek merged commit 0ae33c4 into master Nov 9, 2022
@pomek pomek deleted the i/54 branch November 9, 2022 12:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Use passed package name everywhere in the plugin
3 participants