PHP 클래스 git, gitblog

파일 보기 프로젝트 열기: rsms/gitblog 1 사용 예제들

공개 프로퍼티들

프로퍼티 타입 설명
$query_count Query counter
$status_cache Cached git status structure

공개 메소드들

메소드 설명
add ( $pathspec, $forceIncludeIgnored = true )
cat_file ( $ids )
commit ( $message, $author = null, $pathspec = null, $deferred = false )
config ( $key = null, $value = null, $guess_repo = true ) # -----------------------------------------------------------------------------------------------
diff ( $commits = null, $paths = null, $args = null ) Each argument can be a string or and array of strings (or null to skip)
escargs ( $args )
exec ( $cmd, $input = null, $gitdir = null, $worktree = null, $allow_guess = false, $ignore_git_errors = false ) Execute a git command
id_for_pathspec ( $pathspec ) Retrieve ids for $pathspec (string or array of strings) at the current branch head
init ( $gitdir = null, $worktree = null, $shared = 'true' )
ls_basic ( $args = null, $paths = null )
ls_modified ( $paths = null, $exclude = null )
ls_removed ( $paths = null, $exclude = null )
ls_staged ( $paths = null )
ls_untracked ( $paths = null, $exclude = null )
reset ( $pathspec = null, $commitobj = null, $flags = '-q' )
status ( $raw = false, $cached = true ) : array git status

메소드 상세

add() 정적인 공개 메소드

static public add ( $pathspec, $forceIncludeIgnored = true )

cat_file() 정적인 공개 메소드

static public cat_file ( $ids )

commit() 정적인 공개 메소드

static public commit ( $message, $author = null, $pathspec = null, $deferred = false )

config() 정적인 공개 메소드

# -----------------------------------------------------------------------------------------------
static public config ( $key = null, $value = null, $guess_repo = true )

diff() 정적인 공개 메소드

Each argument can be a string or and array of strings (or null to skip)
static public diff ( $commits = null, $paths = null, $args = null )

escargs() 정적인 공개 메소드

static public escargs ( $args )

exec() 정적인 공개 메소드

Execute a git command
static public exec ( $cmd, $input = null, $gitdir = null, $worktree = null, $allow_guess = false, $ignore_git_errors = false )

id_for_pathspec() 정적인 공개 메소드

Retrieve ids for $pathspec (string or array of strings) at the current branch head
static public id_for_pathspec ( $pathspec )

init() 정적인 공개 메소드

static public init ( $gitdir = null, $worktree = null, $shared = 'true' )

ls_basic() 정적인 공개 메소드

static public ls_basic ( $args = null, $paths = null )

ls_modified() 정적인 공개 메소드

static public ls_modified ( $paths = null, $exclude = null )

ls_removed() 정적인 공개 메소드

static public ls_removed ( $paths = null, $exclude = null )

ls_staged() 정적인 공개 메소드

static public ls_staged ( $paths = null )

ls_untracked() 정적인 공개 메소드

static public ls_untracked ( $paths = null, $exclude = null )

reset() 정적인 공개 메소드

static public reset ( $pathspec = null, $commitobj = null, $flags = '-q' )

status() 정적인 공개 메소드

git status
static public status ( $raw = false, $cached = true ) : array
리턴 array array( 'branch' => 'master', ['upstream' => array('name' => 'origin/master', 'distance' => 24),] ['staged' => array( 'filename' => array('status'=>'added'|'modified'|'deleted') | array('status'=>'renamed','newname'=>'filename') ], ... ),] ['unstaged' => array( 'filename' => array('status'=>'added'|'modified'|'deleted') | array('status'=>'renamed','newname'=>'filename') ], ... ),] ['untracked' => array( 'filename' => 1, ... )] )

프로퍼티 상세

$query_count 공개적으로 정적으로 프로퍼티

Query counter
public static $query_count

$status_cache 공개적으로 정적으로 프로퍼티

Cached git status structure
public static $status_cache