diff options
author | Theodore Nordsieck <theo@opscode.com> | 2013-08-13 17:17:08 -0700 |
---|---|---|
committer | Theodore Nordsieck <theo@opscode.com> | 2013-08-13 17:17:08 -0700 |
commit | 1c87fa07c34c8c8a7395f2ba6eaad97fbb63d837 (patch) | |
tree | 9ce74edfd8e157dceadee7ec30dab5042e88d8d8 | |
parent | 564d3f29c6035ee64d3b42c88d08f3099e724c2f (diff) | |
download | ohai-1c87fa07c34c8c8a7395f2ba6eaad97fbb63d837.tar.gz |
wip
-rw-r--r-- | CROSS_PLATFORM.md | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/CROSS_PLATFORM.md b/CROSS_PLATFORM.md index b9ce8b77..339c7519 100644 --- a/CROSS_PLATFORM.md +++ b/CROSS_PLATFORM.md @@ -1,4 +1,4 @@ -### Terms +## Terms ##### Command @@ -36,7 +36,16 @@ For example, if I made sure to install python and ruby before executing a comman In general, you should only add a string to env if it affects the execution of the command. -### Collecting Data +## Collecting Data -Run the get_output.rb command to collect data. +Run the get_output.rb command to collect data. Both "parameters" and "env" are comma separated lists of strings. If any of the parameters begins with the "-" character, that parameter needs to be adjacent to its flag, as in the example: + ruby get_output.rb -c "python" -p'-c "import sys; print sys.version"' -f "osx-10.8.4" -a x64 -e python + +## Adding data to the library + +To add data to the library, copy the output of the get_output.rb command to the file named <command>.output in the ohai/spec/data/plugins directory. For example, if I collected data using the command + + ruby get_output.rb -c "ls" -p',-l' -f "osx-10.8" -a x64 -e + +I would copy the output and paste it to the end of the ls.output file in ohai/spec/data/plugins. If there is no ls.output file, create one.
\ No newline at end of file |