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

updating the plugin during development #16

Closed
amin-nas opened this issue Feb 20, 2017 · 10 comments
Closed

updating the plugin during development #16

amin-nas opened this issue Feb 20, 2017 · 10 comments

Comments

@amin-nas
Copy link

After a code change and running the build command, how would I go about updating the locally installed plugin?

I ran the link command and I can see the symlink in sketch plugin folder. Not sure what's the purpose of this command.

@mathieudutour
Copy link
Member

Once I have link my plugin, I usually run skpm build --watch and every time I change my code, the plugin is compiled.

If you have enabled the developer mode for sketch (#8), it should just work.

Does it resolve your issue or did I misunderstand?

@amin-nas
Copy link
Author

I have the developer mode enabled, and tried skpm build --watch. I see the plugin being complied on every change. But when I run the plugin from Sketch's Plugin menu, I dont see the update. Wondering if I'm not following the setup instructions correctly.

Attached a screenshot of the Sketch plugins folder.
screen shot 2017-02-20 at 7 22 31 am

@mathieudutour
Copy link
Member

is the symlink going to the right place?

@amin-nas
Copy link
Author

I believe so. Is the expectation that after running the skpm link command, the plugin is automatically installed? I assumed that's the purpose of it, but it didn't happen on my side.

screen shot 2017-02-20 at 7 36 11 am

@mathieudutour
Copy link
Member

yes i should (but there could be a bug). If you right-click -> Show information on the symlink, it should show were it's pointing to

@amin-nas
Copy link
Author

Just started a fresh project and followed the steps. All the commands were executed successfully, but here's what I see after:
screen shot 2017-02-20 at 7 53 42 am
Also, the new plugin does not appear under Sketch plugins menu (tried restarting Sketch).

@mathieudutour
Copy link
Member

I just fixed a bug when specifying the absolute path to the plugin instead of the relative path. Does it fix your issue?

@amin-nas
Copy link
Author

Updated and created a new project. The symlink is pointing to the package.json file now:
/Users/aminnassiri/Projects/skpm_test_3/package.json

@mathieudutour
Copy link
Member

Oh I'm tired sorry. Should work now. (no need to create a new project, just run the link command again)

@amin-nas
Copy link
Author

Sweet! Working perfectly 🙌

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

No branches or pull requests

2 participants