-
Notifications
You must be signed in to change notification settings - Fork 24
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
Path to Scripts Does Not Work For Tokenized Paths or For Paths Relative to Config File Path #18
Comments
Hi, What arguments are you passing the -Ben |
Thanks for your reply! I am using $(configDirectory). Sorry, I typed that wrong here, but had it correct in the config:
Here is my Gulp script which uses -c (adapted from a SitecoreMasters post). I went to check what the arguments were, but was getting an exception for a missing dependency at the time and forgot to check later:
|
I believe I have found the source of the issue (why it is neither detokenizing configDirectory nor starting from the configDirectory by default as I assumed all paths would do given this comment in Leprechaun.config). I think it is this block:
Perhaps it can be refactored to work similarly to this (and surrounding code)?:
Thanks, |
we came to similar conclusions 😃 ddf704d Can you try this exe and see if that solves your problem? It'll ensure that all relative paths are converted to absolute, using the path to the exe as the base. |
Hi, Thanks for the reply, but that seems to be causing a new problem: it seems to be looking for the Leprechaun.config in a combination of the exe path and the path I'm specifying for the Leprechaun.config. This is the problem that I was having with the code gen scripts (e.g. Synthesis.csx) path as well. Here is the shortened log error: I have a feeling there may be a misunderstanding from reading your last comment as well. I was hoping that Leprechaun would use the configDirectory as the base for forming the path to the scripts (and also the Leprechaun.config at this point as it was before). It was having an issue finding the config file before, just the scripts files. Thanks again! |
I'll take a closer look tomorrow afternoon and get back to you. I agree - I think I misunderstood the issue you were having. |
Per our outside conversation, I changed the way the path to the config was specified as you suggested (..\..\src\Foundation\CodeGen\code\Leprechaun.config instead of .\src\Foundation\CodeGen\code\Leprechaun.config) and that resolved all issues with paths - thank you! Just a reminder that the version of the Runner package with the fix (1.0.1-pre02) is not on NuGet yet. |
@DavidMtbg It's on its way up to NuGet now 😃 |
This was merged in a long time ago. Closed. |
I'm trying to use the NuGet package version and specify the path to the scripts which I want in source control (but not the binaries), but Leprechaun seems to always append whatever path I specify to the path where the executable is (/packages/Leprechaun + /...) which is not to be in source control.
I've tried tokenized paths like $(ConfigDirectory), ./../../../Foundation/... and others, but it's always appended.
Here is the error output I'm getting since it can't find the scripts below the exe in the NuGet packages folder:
The text was updated successfully, but these errors were encountered: