src/console/orbit.php
public function action_uninstall( $params ) {
		
		$path = $params[0]; 
		
		if ( empty( $path ) ) {
			CCCli::line( 'no ship path given.', 'red' ); return;
		}
		
		/*
		 * direct install if starting with /
		 */
		if ( substr( $path, 0, 1 ) == '/' ) {
			
			// fix path
			if ( substr( $path, -1 ) != '/' ) {
				$path .= '/';
			}
			
			// is directory
			if ( !is_dir( $path ) ) {
				CCCli::line( 'could not find a ship at path: '.$path, 'red' ); return;
			}
			
			// are ya serius..
			if ( !CCCli::confirm( "are you sure you want to uninstall this ship?", true ) ) {
				return;
			}
			
			// run the uninstaller
			try {
				\CCOrbit::uninstall( $path );
			}
			catch ( \Exception $e ) {
				CCCli::line( $e->getMessage(), 'red' ); 
				CCCli::line( 'ship destroying failure.', 'red' ); return;
			}
			
			// also remove the direcoty?
			if ( CCCli::confirm( "do you also wish to remove the ship files?", true ) ) {
				\CCFile::delete( $path );
			}
			
			// we are done
			CCCli::line( 'ship destroyed!', 'green' );
			
			return;
		}
		
		// check if the module is in our orbit path
		if ( is_dir( ORBITPATH.$path ) ) {
			
			// there is a ship yay
			CCCli::line( 'found ship at path: '.ORBITPATH.$path, 'green' );
			
			return static::action_uninstall( array( ORBITPATH.$path ) );
		}
	
		// nothing to do here
		CCCli::line( 'could not find a ship at this path or name.', 'red' ); return;
	}
public function action_uninstall( $params ) {
		
		$path = $params[0]; 
		
		if ( empty( $path ) ) {
			CCCli::line( 'no ship path given.', 'red' ); return;
		}
		
		/*
		 * direct install if starting with /
		 */
		if ( substr( $path, 0, 1 ) == '/' ) {
			
			// fix path
			if ( substr( $path, -1 ) != '/' ) {
				$path .= '/';
			}
			
			// is directory
			if ( !is_dir( $path ) ) {
				CCCli::line( 'could not find a ship at path: '.$path, 'red' ); return;
			}
			
			// are ya serius..
			if ( !CCCli::confirm( "are you sure you want to uninstall this ship?", true ) ) {
				return;
			}
			
			// run the uninstaller
			try {
				\CCOrbit::uninstall( $path );
			}
			catch ( \Exception $e ) {
				CCCli::line( $e->getMessage(), 'red' ); 
				CCCli::line( 'ship destroying failure.', 'red' ); return;
			}
			
			// also remove the direcoty?
			if ( CCCli::confirm( "do you also wish to remove the ship files?", true ) ) {
				\CCFile::delete( $path );
			}
			
			// we are done
			CCCli::line( 'ship destroyed!', 'green' );
			
			return;
		}
		
		// check if the module is in our orbit path
		if ( is_dir( ORBITPATH.$path ) ) {
			
			// there is a ship yay
			CCCli::line( 'found ship at path: '.ORBITPATH.$path, 'green' );
			
			return static::action_uninstall( array( ORBITPATH.$path ) );
		}
	
		// nothing to do here
		CCCli::line( 'could not find a ship at this path or name.', 'red' ); return;
	}
public function action_uninstall ( $ params ) { $ path = $ params [ 0 ] ; if ( empty ( $ path ) ) { CCCli :: line ( 'no ship path given.' , 'red' ) ; return ; } /*
		 * direct install if starting with /
		 */ if ( substr ( $ path , 0 , 1 ) == '/' ) { // fix path if ( substr ( $ path , - 1 ) != '/' ) { $ path .= '/' ; } // is directory if ( ! is_dir ( $ path ) ) { CCCli :: line ( 'could not find a ship at path: ' . $ path , 'red' ) ; return ; } // are ya serius.. if ( ! CCCli :: confirm ( "are you sure you want to uninstall this ship?" , true ) ) { return ; } // run the uninstaller try { \ CCOrbit :: uninstall ( $ path ) ; } catch ( \ Exception $ e ) { CCCli :: line ( $ e -> getMessage ( ) , 'red' ) ; CCCli :: line ( 'ship destroying failure.' , 'red' ) ; return ; } // also remove the direcoty? if ( CCCli :: confirm ( "do you also wish to remove the ship files?" , true ) ) { \ CCFile :: delete ( $ path ) ; } // we are done CCCli :: line ( 'ship destroyed!' , 'green' ) ; return ; } // check if the module is in our orbit path if ( is_dir ( ORBITPATH . $ path ) ) { // there is a ship yay CCCli :: line ( 'found ship at path: ' . ORBITPATH . $ path , 'green' ) ; return static :: action_uninstall ( array ( ORBITPATH . $ path ) ) ; } // nothing to do here CCCli :: line ( 'could not find a ship at this path or name.' , 'red' ) ; return ; }
uninstall an orbit module

@param array 		$params
uninstall an orbit module