Commit Graph

306 Commits

Author SHA1 Message Date
Han-Wen Nienhuys
2710e51e06 Merge branch 'master' of git://repo.or.cz/fast-export 2007-06-08 18:19:23 -03:00
Han-Wen Nienhuys
8e26f9c2bb print error message when p4 print fails (eg. due to permission problems) 2007-06-08 18:19:16 -03:00
Simon Hausmann
f4b5d09a6a Only get the expensive branch mapping from the p4 server when not
syncing with the help of an origin remote (which we instead then use
to get new branches from).
2007-06-08 08:49:22 +02:00
Simon Hausmann
59a2926517 Make git-p4 submit detect the correct reference (origin) branch when
working with multi-branch imports.

Signed-off-by: Simon Hausmann <simon@lst.de>
2007-06-07 22:54:32 +02:00
Simon Hausmann
7f182ef1b0 Make clone behave like git clone by default again.
Signed-off-by: Simon Hausmann <simon@lst.de>
2007-06-07 21:52:12 +02:00
Marius Storm-Olsen
853e41475e Exclude the HEAD symbolic ref from the list of known branches 2007-06-07 15:28:04 +02:00
Marius Storm-Olsen
275f02aadc Fix single branch import into remotes 2007-06-07 15:13:59 +02:00
Marius Storm-Olsen
553b6a4a99 Fix git-p4 clone (defaultDestination) 2007-06-07 15:08:33 +02:00
Marius Storm-Olsen
b7bf365514 Ensure that the commit message is Windows formated (CRLF) before invoking the editor.
(The default editor on Windows (Notepad) doesn't handle Unix line endings)

Signed-off-by: Marius Storm-Olsen <marius@trolltech.com>
2007-06-07 14:11:15 +02:00
Simon Hausmann
6ce8e50925 Fix depot-path determination for git-p4 submit 2007-06-07 13:10:20 +02:00
Simon Hausmann
a72cdbe18d Fix git-p4 submit 2007-06-07 13:09:14 +02:00
Simon Hausmann
bf109db2b2 Fix git-p4 rebase 2007-06-07 12:51:03 +02:00
Simon Hausmann
94d5e2bc84 Hack to make the multi-branch import work again with self.depotPaths now that
self.depotPath is gone
2007-06-07 09:41:53 +02:00
Simon Hausmann
afd960f59b Don't attempt to set the initialParent on multi-branch imports (useless).
At some point the code paths should be unified, but for now I need a working
git-p4 :)
2007-06-07 09:39:51 +02:00
Simon Hausmann
74b0014a7a Fix common path "calculation" from logs of multiple branches.
Need to use min instead of max for prev/cur to avoid out-of-bounds
string access. Also treat "i" as index of the last match instead of
a length because in case of a complete match of the two strings
i was off by one.
2007-06-07 09:37:13 +02:00
Simon Hausmann
51944c93af Fix support for "depot-path" in older git-p4 imports 2007-06-07 09:19:34 +02:00
Han-Wen Nienhuys
eb4a85cc97 look for 'text' and 'binary' files. 2007-06-05 20:29:59 -03:00
Han-Wen Nienhuys
97dabfacd8 thinko: really ignore deleted files. 2007-05-31 14:21:58 -03:00
Han-Wen Nienhuys
a196ae17a6 remove debug print 2007-05-31 12:40:24 -03:00
Han-Wen Nienhuys
f1d3db44f5 Cleanups & import into p4/master for local import
- import into master/local if --import-local is set

- use Die() for exiting

- if --verbose is set, raise Exception()

- use joined strings iso. `list` for progress printing
2007-05-31 12:38:30 -03:00
Han-Wen Nienhuys
449242bc4c use p4CmdList() to get file contents in Python dicts. This is more robust. 2007-05-31 11:29:25 -03:00
Han-Wen Nienhuys
6b6e82375b only run p4 print if necessary 2007-05-30 18:50:41 -03:00
Han-Wen Nienhuys
9261cdfd99 don't p4 print deleted files. 2007-05-30 17:33:18 -03:00
Han-Wen Nienhuys
afdbaf0593 read files before creating the commit. 2007-05-30 16:57:59 -03:00
Han-Wen Nienhuys
0be300b90e thinko. 2007-05-30 16:38:32 -03:00
Han-Wen Nienhuys
3c1c54742c store p4 user cache in home directory. 2007-05-30 16:35:32 -03:00
Han-Wen Nienhuys
5016361592 Thinko, fix buglet. 2007-05-30 16:22:57 -03:00
Han-Wen Nienhuys
6460cf12df Read p4 files in one batch. 2007-05-30 16:21:46 -03:00
Han-Wen Nienhuys
c246e21090 remove global .gitdir 2007-05-30 13:58:19 -03:00
Han-Wen Nienhuys
ae38e155d0 Merge origin. 2007-05-30 13:46:25 -03:00
Han-Wen Nienhuys
49ae8869e7 Diverse cleanups
- print commands with \n

- extractDepotPathsAndChangeFromGitLog -> extractSettings, returning
dict.

- store keepRepoPath in [git-p4: ] line

- create a main() function, so git-p4 can be pychecked

- use --destination for clone destination. This simplifies logic
for --keep-path
2007-05-30 13:44:15 -03:00
Simon Hausmann
458e0545cb Fix typo in listExistingP4Branches that broke sync. 2007-05-28 19:24:57 +02:00
Simon Hausmann
e49c494d27 In *_pipe print the command that failed if it fails.
Fixed old calls to mypopen.
2007-05-28 19:23:19 +02:00
Han-Wen Nienhuys
e274d94177 Extract multiple paths concurrently.
This enables importing just the interesting bits of large
repositories.
2007-05-28 12:50:04 -03:00
Han-Wen Nienhuys
aba960de59 add --verbose to all commands. 2007-05-28 11:45:26 -03:00
Han-Wen Nienhuys
79904ad286 use strip() iso. slicing for removing \n 2007-05-28 11:20:50 -03:00
Han-Wen Nienhuys
0e303e401d use string.strip() iso. slicing. 2007-05-28 11:19:10 -03:00
Han-Wen Nienhuys
b1c7b0866f clone and sync --keep-path to keep perforce path to module. 2007-05-28 11:18:31 -03:00
Han-Wen Nienhuys
7c32565090 minor cleanups 2007-05-28 11:17:27 -03:00
Han-Wen Nienhuys
829dde7184 cleanup
- use re.sub() iso. if for stripping ...
- spacing nits
2007-05-28 11:15:43 -03:00
Han-Wen Nienhuys
3c81f33f48 Robustness fixes for pipes
- add read_pipe(), read_pipe_lines(), write_pipe(), which
check pipe.close()

- use throughout
2007-05-28 11:15:29 -03:00
Han-Wen Nienhuys
73a8a9786e add .dotest to .gitignore 2007-05-28 11:08:19 -03:00
Simon Hausmann
481694a31a Fix my email address, this isn't really KDE related :) 2007-05-28 14:43:25 +02:00
Han-Wen Nienhuys
e22b86f010 rename apply() to applyCommit(); apply is a python builtin 2007-05-28 14:29:11 +02:00
Han-Wen Nienhuys
bd609cfd0f reformatting: break long lines. 2007-05-28 14:28:58 +02:00
Han-Wen Nienhuys
a05b21cd97 Cleanups
- don't use dir (python builtin)
- use re for munging depotPath into destination
2007-05-28 14:22:53 +02:00
Simon Hausmann
175ea59305 Fix creation of refs/remotes/p4/HEAD symbolic ref 2007-05-27 15:48:01 +02:00
Simon Hausmann
741db7fa74 Added git-p4 submit --trust-me-like-a-fool for the adventurous users :) 2007-05-25 22:34:30 +02:00
Simon Hausmann
f5af3efa26 Forgot to remove this TODO item when I made --with-origin the default :) 2007-05-25 19:43:38 +02:00
Simon Hausmann
7116f99151 Shortcut the case where we have no origin branch 2007-05-25 11:36:42 +02:00