Documentation for kickstart namespace commands
This commit is contained in:
		
							
								
								
									
										10
									
								
								docs/kickstart/codename.md
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										10
									
								
								docs/kickstart/codename.md
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,10 @@ | ||||
| # kickstart.codename | ||||
| Prints the codename for the distro. For Ubuntu so far. | ||||
|  | ||||
|  | ||||
| ### Example | ||||
|  | ||||
| ```bash | ||||
| $ kickstart.codename | ||||
| precise | ||||
| ``` | ||||
							
								
								
									
										8
									
								
								docs/kickstart/command_exists.md
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										8
									
								
								docs/kickstart/command_exists.md
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,8 @@ | ||||
| # kickstart.command_exists command_name | ||||
| Return 0 if commands is present on the current path, or 1 when it is not | ||||
|  | ||||
| ### Example | ||||
|  | ||||
| ```bash | ||||
| $ kickstart.command_exists node || echo "Node not found" | ||||
| ``` | ||||
							
								
								
									
										14
									
								
								docs/kickstart/context.md
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										14
									
								
								docs/kickstart/context.md
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,14 @@ | ||||
| # kickstart.context current_context | ||||
| Store the current context so kickstart.mute and kickstart.info can append the information | ||||
|  | ||||
| ### Example | ||||
|  | ||||
| ```bash | ||||
| $ kickstart.info Some information | ||||
| Some information | ||||
|  | ||||
| $ kickstart.context Ubuntu | ||||
| Setting up Ubuntu | ||||
| $ kickstart.info Some information | ||||
| Ubuntu >> Some information | ||||
| ``` | ||||
							
								
								
									
										11
									
								
								docs/kickstart/mute.md
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										11
									
								
								docs/kickstart/mute.md
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,11 @@ | ||||
| # kickstart.mute command to run | ||||
| Run the command with stdout and stder outputing to /dev/null. | ||||
| Inform it is about to run. | ||||
| Returns the command result | ||||
|  | ||||
| ### Example | ||||
|  | ||||
| ```bash | ||||
| $ kickstart.mute id root | ||||
| Runnig "id root" | ||||
| ``` | ||||
							
								
								
									
										11
									
								
								docs/kickstart/os.md
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										11
									
								
								docs/kickstart/os.md
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,11 @@ | ||||
| # kickstart.os | ||||
| Print the current operational system name | ||||
|  | ||||
|  | ||||
| ### Example | ||||
| ``` | ||||
| $ kickstart.os | ||||
| Ubuntu | ||||
| $ kickstart.os | ||||
| Mac | ||||
| ``` | ||||
							
								
								
									
										12
									
								
								docs/kickstart/os/is.md
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										12
									
								
								docs/kickstart/os/is.md
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,12 @@ | ||||
| # kickstart.os.is os_name | ||||
| Returns 0 if we are on the expected OS and 1 if not. | ||||
|  | ||||
| ### Example | ||||
|  | ||||
| ```bash | ||||
| $ kickstart.os.is Ubuntu && echo We are on Ubuntu | ||||
| $ ! kickstart.os.is Mac && echo We are not on Mac | ||||
| $ if [ kickstart.os.is Ubuntu ]; then | ||||
|     echo Getting into Ubuntu system | ||||
|   fi | ||||
| ``` | ||||
		Reference in New Issue
	
	Block a user