-
Notifications
You must be signed in to change notification settings - Fork 433
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
Allowing relative script file references #1132
Conversation
add3481
to
c84165f
Compare
c84165f
to
40f8b1f
Compare
Looks good! How will this interact with script host file watching? |
Good question! This would currently rely on |
40f8b1f
to
4683a45
Compare
string scriptPath = fileSystem.Path.Combine(scriptDirectory, scriptFileName); | ||
if (!fileSystem.File.Exists(scriptPath)) | ||
{ | ||
throw new ConfigurationErrorsException("Invalid script file name configuration. The 'scriptFileName' property is set to a file that does not exist."); |
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.
The property is called "scriptFile" right?
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.
Maybe rename local var to scriptFile, since it can actually be a path.
@@ -0,0 +1,16 @@ | |||
{ | |||
"scriptFile": "../HttpTrigger/index.js", |
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.
You used \ in a previous example, here you're using /. Intentional?
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.
It was.... just wanted to have a sample and test with the variation
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.
One minor comment
f92c060
to
b9f6750
Compare
b9f6750
to
690b13d
Compare
This enables relative references to script files, primarily addressing the need to reference shared precompiled assemblies, but enabling this for other languages as well.
With this changes, relative references like this are now supported:
"scriptFile":"..\\shared\\myassembly.dll"