2012-09-27 17 views
14

wiem, że mogę skonfigurować foldery i pliki są ignorowane przez Subversion za pomocą następujących poleceń:Jak skonfigurować ustawienia ignorowania svn za pomocą git svn?

svn propset svn:ignore build . // Ignores the build folder. 
svn propedit svn:ignore . // Opens an editor. 

Chociaż używam git svn do kasy repozytorium przechowywane na serwerze Subversion. Nie mogłem znaleźć polecenia konfigurowania w ten sposób. Poniższa lista zawiera wszystkie polecenia, które są sugerowane przez zsh zakończenia dla git svn:

$ git svn 
blame   -- show what revision and author last modified each line of a file: 
branch   -- create a branch in the SVN repository 
clone   -- same as init, followed by fetch 
commit-diff  -- commit diff of two tree-ishs 
create-ignore -- recursively finds the svn:ignore property and creates .gitignore files 
dcommit   -- commit diffs from given head onto SVN repository 
fetch   -- fetch revisions from the SVN remote 
find-rev  -- output git commit corresponding to the given SVN revision's hash 
info   -- show information about a file or directory 
init   -- initialize an empty git repository with additional svn data 
log    -- output SVN log-messages 
propget   -- get a given SVN property for a file 
proplist  -- list the SVN properties stored for a file or directory 
rebase   -- fetch revs from SVN parent of HEAD and rebase current work on it 
set-tree  -- commit given commit or tree to SVN repository 
show-externals -- show the subversion externals 
show-ignore  -- output corresponding toplevel .gitignore file of svn:ignore 
tag    -- create a tag in the SVN repository 

Pytanie:

  • Wiesz, czy istnieje jakikolwiek sposób, aby edytować Subversion ignorować konfigurację poprzez git svn?

Odpowiedz

9

Nie, git-svn obsługuje tylko tworzenie .gitignore przez svn: ignore. Aby ustawić svn: ignore was mogą

  1. Zastosowanie svn propset svn:ignore 'value' URL gdzie URL można uzyskać przez (git-svn git svn info path/to/directory | awk '/URL:/{print $2}') Więc można napisać własne „svn_propset.sh” skrypt. Aby zsynchronizować plik .gitignore z svn: ignore, uruchom git svn create-ignore

  2. Użyj dowolnego narzędzia, które pozwala .gitignore < -> svn: ignore translation. Znam tylko dwa: SmartGit (strona klienta, uwaga: potrzebny jest świeży klon, aby włączyć ignorowanie obsługi) i SubGit (po stronie serwera, musisz mieć dostęp do serwera z SVN). W tym przypadku svn: ignore jest ustawiony na popychaniu lokalnego zatwierdzenia do repozytorium SVN (dla SmartGit)/Git (dla SubGit).