private function get_raw_git_version( $version ) {
		if ( '' === $version ) {
			return 'master';
		}

		// If Composer hash given then just use whatever's after it.
		$hash_pos = strpos( $version, '#' );
		if ( false !== $hash_pos ) {
			return substr( $version, $hash_pos + 1 );
		}

		// Strip any Composer 'dev-' prefix.
		if ( 0 === strncmp( $version, 'dev-', 4 ) ) {
			$version = substr( $version, 4 );
		}

		// Ignore/strip any relative suffixes.
		return str_replace( [ '^', '~' ], '', $version );
	}
private function get_raw_git_version( $version ) {
		if ( '' === $version ) {
			return 'master';
		}

		// If Composer hash given then just use whatever's after it.
		$hash_pos = strpos( $version, '#' );
		if ( false !== $hash_pos ) {
			return substr( $version, $hash_pos + 1 );
		}

		// Strip any Composer 'dev-' prefix.
		if ( 0 === strncmp( $version, 'dev-', 4 ) ) {
			$version = substr( $version, 4 );
		}

		// Ignore/strip any relative suffixes.
		return str_replace( [ '^', '~' ], '', $version );
	}
private function get_raw_git_version ( $ version ) { if ( '' === $ version ) { return 'master' ; } // If Composer hash given then just use whatever's after it. $ hash_pos = strpos ( $ version , '#' ) ; if ( false !== $ hash_pos ) { return substr ( $ version , $ hash_pos + 1 ) ; } // Strip any Composer 'dev-' prefix. if ( 0 === strncmp ( $ version , 'dev-' , 4 ) ) { $ version = substr ( $ version , 4 ) ; } // Ignore/strip any relative suffixes. return str_replace ( [ '^' , '~' ] , '' , $ version ) ; }
Get the version to use for raw github request. Very basic.

@string $version Package version.
@string Version to use for github request.
Get the version to use for raw github request . Very basic .