##// END OF EJS Templates
merge with stable
Thomas Arendsen Hein -
r4045:1bd6868b merge default
parent child Browse files
Show More
@@ -2372,8 +2372,7 b' def status(ui, repo, *pats, **opts):'
2372 files, matchfn, anypats = cmdutil.matchpats(repo, pats, opts)
2372 files, matchfn, anypats = cmdutil.matchpats(repo, pats, opts)
2373 cwd = (pats and repo.getcwd()) or ''
2373 cwd = (pats and repo.getcwd()) or ''
2374 modified, added, removed, deleted, unknown, ignored, clean = [
2374 modified, added, removed, deleted, unknown, ignored, clean = [
2375 [util.pathto(cwd, x) for x in n]
2375 n for n in repo.status(node1=node1, node2=node2, files=files,
2376 for n in repo.status(node1=node1, node2=node2, files=files,
2377 match=matchfn,
2376 match=matchfn,
2378 list_ignored=all or opts['ignored'],
2377 list_ignored=all or opts['ignored'],
2379 list_clean=all or opts['clean'])]
2378 list_clean=all or opts['clean'])]
@@ -2398,11 +2397,11 b' def status(ui, repo, *pats, **opts):'
2398 format = "%s %%s%s" % (char, end)
2397 format = "%s %%s%s" % (char, end)
2399
2398
2400 for f in changes:
2399 for f in changes:
2401 ui.write(format % f)
2400 ui.write(format % util.pathto(cwd, f))
2402 if ((all or opts.get('copies')) and not opts.get('no_status')):
2401 if ((all or opts.get('copies')) and not opts.get('no_status')):
2403 copied = repo.dirstate.copied(f)
2402 copied = repo.dirstate.copied(f)
2404 if copied:
2403 if copied:
2405 ui.write(' %s%s' % (copied, end))
2404 ui.write(' %s%s' % (util.pathto(cwd, copied), end))
2406
2405
2407 def tag(ui, repo, name, rev_=None, **opts):
2406 def tag(ui, repo, name, rev_=None, **opts):
2408 """add a tag for the current or given revision
2407 """add a tag for the current or given revision
@@ -344,12 +344,14 b' class ui(object):'
344 user = self.config("ui", "username")
344 user = self.config("ui", "username")
345 if user is None:
345 if user is None:
346 user = os.environ.get("EMAIL")
346 user = os.environ.get("EMAIL")
347 if not user:
347 if user is None:
348 try:
348 try:
349 user = '%s@%s' % (util.getuser(), socket.getfqdn())
349 user = '%s@%s' % (util.getuser(), socket.getfqdn())
350 self.warn(_("No username found, using '%s' instead\n") % user)
350 except KeyError:
351 except KeyError:
351 raise util.Abort(_("Please specify a username."))
352 pass
352 self.warn(_("No username found, using '%s' instead\n") % user)
353 if not user:
354 raise util.Abort(_("Please specify a username."))
353 return user
355 return user
354
356
355 def shortuser(self, user):
357 def shortuser(self, user):
@@ -59,3 +59,22 b' hg incoming bundle://../full.hg'
59 hg -R bundle://../full.hg outgoing ../partial2
59 hg -R bundle://../full.hg outgoing ../partial2
60 hg -R bundle://../does-not-exist.hg outgoing ../partial2
60 hg -R bundle://../does-not-exist.hg outgoing ../partial2
61 cd ..
61 cd ..
62
63 # test for 540d1059c802
64 hg init orig
65 cd orig
66 echo foo > foo
67 hg add foo
68 hg ci -m 'add foo' -d '0 0'
69
70 hg clone . ../copy
71 hg tag -d '0 0' foo
72
73 cd ../copy
74 echo >> foo
75 hg ci -m 'change foo' -d '0 0'
76 hg bundle ../bundle.hg ../orig
77
78 cd ../orig
79 hg incoming ../bundle.hg
80 cd ..
@@ -209,3 +209,13 b' date: Mon Jan 12 13:46:40 1970 +0'
209 summary: 0.3m
209 summary: 0.3m
210
210
211 abort: No such file or directory: ../does-not-exist.hg
211 abort: No such file or directory: ../does-not-exist.hg
212 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
213 searching for changes
214 searching for changes
215 changeset: 2:ed1b79f46b9a
216 tag: tip
217 parent: 0:bbd179dfa0a7
218 user: test
219 date: Thu Jan 01 00:00:00 1970 +0000
220 summary: change foo
221
@@ -24,5 +24,8 b' echo 1 > asdf'
24 hg commit -d '1000000 0' -u "foo@bar.com" -m commit-1
24 hg commit -d '1000000 0' -u "foo@bar.com" -m commit-1
25 hg tip
25 hg tip
26 echo 123 > asdf
26 echo 123 > asdf
27 echo "[ui]" > .hg/hgrc
28 echo "username = " >> .hg/hgrc
29 hg commit -d '1000000 0' -m commit-1
27 rm .hg/hgrc
30 rm .hg/hgrc
28 hg commit -d '1000000 0' -m commit-1 2>&1 | sed -e "s/'[^']*'/user@host/"
31 hg commit -d '1000000 0' -m commit-1 2>&1 | sed -e "s/'[^']*'/user@host/"
@@ -22,4 +22,7 b' user: foo@bar.com'
22 date: Mon Jan 12 13:46:40 1970 +0000
22 date: Mon Jan 12 13:46:40 1970 +0000
23 summary: commit-1
23 summary: commit-1
24
24
25 abort: Please specify a username.
26 transaction abort!
27 rollback completed
25 No username found, using user@host instead
28 No username found, using user@host instead
General Comments 0
You need to be logged in to leave comments. Login now