How to run kanel in an app using a forked version of this repo? #371
Replies: 13 comments 7 replies
-
I might be missing something but it looks like your version wasn't built? Did you run |
Beta Was this translation helpful? Give feedback.
-
When in my local clone of my fork of kanel, I run Now back to my application, where I have my fork as a dependency. This is the package.json of that application
The 2 screenshots in my first comment are from that application. As you can see, in the build directory there is not what would be the build result of my code. It seems unlikely that I need to go inside of node_modules/kanel-monorepo/packages/kanel to run The problem I'm having should be easy to replicate. In any app where you already have kanel as dependancy, try to replace that with my fork, do yarn install, and see what's inside node_modules/kanel/build/generators/resolveType.js. |
Beta Was this translation helpful? Give feedback.
-
Looking at your screenshots, you see your changes in a |
Beta Was this translation helpful? Give feedback.
-
Right, I think I understood that the second screenshot is from your clone, and the first one is from where you installed it? |
Beta Was this translation helpful? Give feedback.
-
What does ls -la node_modules/.bin/kanel give you? |
Beta Was this translation helpful? Give feedback.
-
Beta Was this translation helpful? Give feedback.
-
Oh, so you have both the regular Kanel installed as well as your fork? |
Beta Was this translation helpful? Give feedback.
-
I don't think so, because this is the only thing I installed:
And the earlier package.json I showed and the screenshots I showed are the result of just that... |
Beta Was this translation helpful? Give feedback.
-
I'm going to try that again, with a fresh blank app. |
Beta Was this translation helpful? Give feedback.
-
|
Beta Was this translation helpful? Give feedback.
-
No. I suggest you |
Beta Was this translation helpful? Give feedback.
-
Ah of course, it's adding it because the mono repo itself refers to kanel (https://github.com/kristiandupont/kanel/blob/master/package.json#L32) -- maybe remove that in your fork. But you will need to manually create a symbolic link to the built version to run the cli. |
Beta Was this translation helpful? Give feedback.
-
Well the thing is that you are not installing Kanel but the mono-repo the way you are doing it. The mono-repo doesn't have any CLI or anything, nor should it. The package itself is just in the |
Beta Was this translation helpful? Give feedback.
-
I have made a fork from this repo with some minor changes that will also try to look for a target in the views.
The problem is that when I run
yarn exec kanel
that it runs the version of https://github.com/kristiandupont/kanel.Let's dive in.
I've added my fork to some repo like this.
yarn add -D https://github.com/christiaanwesterbeek/kanel#additional-views-support
In the dependencies in node_modules, I can actually see my changes here
But not here
So, my question is how can I add my fork of kanel to some repo and execute kanel using my forks code, instead of kristiandupont's?
Beta Was this translation helpful? Give feedback.
All reactions