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

Launchd environment #261

Merged
merged 5 commits into from
Sep 14, 2012
Merged

Launchd environment #261

merged 5 commits into from
Sep 14, 2012

Conversation

martinisoft
Copy link
Contributor

This is an enhancement to the launchd exporter to also bring in environment variables defined and to ensure the program arguments are called correctly. Under the hood, launchd uses exec() which expects each string in the array to be a piece of the command arguments.

Another new piece of functionality is that you can now optionally use the trim_whitespace mode in your ERB templates by adding a - to the ERB tags.

Also, this is how I felt when the specs passed and I learned how launchd uses exec():
YES

This adds whitespace supression optionally, similar to the default
behavior in Rails ActionView ERB templates.

Just add - to a %> like so: -%> and it will remove trailing whitespace
and newlines. This can also be done to the beginning tag for removing
newlines from the beginning of the tag line.
Also suppresses the deprecation warning for the launchd exporter when
using port instead of engine.port_for
launchd uses exec() under the hood when you specify ProgramArguments
or Program so you must break apart program arguments into separate
strings in an array or the command will fail
@mxswd
Copy link
Contributor

mxswd commented Sep 13, 2012

Thanks! This works much better. 😄

ddollar added a commit that referenced this pull request Sep 14, 2012
@ddollar ddollar merged commit 98af1f0 into ddollar:master Sep 14, 2012
@ddollar
Copy link
Owner

ddollar commented Sep 14, 2012

Thanks!

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.

3 participants