equal
deleted
inserted
replaced
253 |
253 |
254 With <name>, set the current branch name. Otherwise, show the |
254 With <name>, set the current branch name. Otherwise, show the |
255 current branch name. |
255 current branch name. |
256 """ |
256 """ |
257 |
257 |
258 if label is not None: |
258 if label: |
259 repo.opener("branch", "w").write(util.fromlocal(label) + '\n') |
259 repo.dirstate.setbranch(util.fromlocal(label)) |
260 else: |
260 else: |
261 b = util.tolocal(repo.workingctx().branch()) |
261 ui.write("%s\n" % util.tolocal(repo.dirstate.branch())) |
262 if b: |
|
263 ui.write("%s\n" % b) |
|
264 |
262 |
265 def branches(ui, repo): |
263 def branches(ui, repo): |
266 """list repository named branches |
264 """list repository named branches |
267 |
265 |
268 List the repository's named branches. |
266 List the repository's named branches. |