Commit Graph

17 Commits

Author SHA1 Message Date
mpm@selenic.com
f95bf8d95c import and startup cleanups
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

import and startup cleanups

add commands:run()
add copyright notice to commands
eliminate/reorganize imports to speed up start time:

0.5b:
$ time bash -c 'for i in `seq 100`; do ~/bin/hg > /dev/null; done'

real    0m7.718s
user    0m6.719s
sys     0m0.794s

new:

$ time bash -c 'for i in `seq 100`; do hg > /dev/null; done'
real    0m2.171s
user    0m1.684s
sys     0m0.444s

just python:

$ time bash -c 'for i in `seq 100`; do python -c pass; done'
real    0m0.988s
user    0m0.771s
sys     0m0.207s

Ignoring the fixed cost of loading the Python interpreter, we're 5.6
times faster. With the Python load time, we're still 3.5 times faster.

manifest hash: acce5882a55c76eb165316f5741724c8ce4ef587
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)

iD8DBQFCoihAywK+sNU5EO8RAqMdAJwMe6Ur0R9G6jjayNa5hH2C3c4k/gCeIYvc
N178vaWWGciX9zq+g5qCAls=
=buhv
-----END PGP SIGNATURE-----
2005-06-04 14:16:32 -08:00
mpm@selenic.com
0b9e66eded migrate remaining commands
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

migrate remaining commands

This removes basically everything from the top-level hg script

manifest hash: 34883e89d8def30e28936b38a9342d2f650f4c94
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)

iD8DBQFCoiD7ywK+sNU5EO8RAh0cAKCeOO9vahYs0tGmMNKk8bflw35p2wCgr6Wr
y0SNLHSVBMCzXtC9zlfDPog=
=3nJx
-----END PGP SIGNATURE-----
2005-06-04 13:45:31 -08:00
mpm@selenic.com
cede7eda00 migrate verify
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

migrate verify

Move the bulk of the verify code into the localrepository class and move
the command into commands.py

manifest hash: 793a8d0094d56ab0a411cd11d7fe7f39c923f209
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)

iD8DBQFCog33ywK+sNU5EO8RApfBAJ4mCmiMmZE1fEfbR6sA+aP1csPvqQCfXHzY
3XK7yc19AivXf5HGKEOL3eM=
=GISf
-----END PGP SIGNATURE-----
2005-06-04 12:24:23 -08:00
mpm@selenic.com
58e0ba5a39 Migrate rawcommit, import, export, history, and merge
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Migrate rawcommit, import, export, history, and merge

manifest hash: f932108ee40e34b460e94b6fe60d6a06ac9f760c
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)

iD8DBQFCoguVywK+sNU5EO8RAtohAKCe9Qr5R+YeLRluJlTxRGrJW/nnoQCfW/+F
I0BSOeNpb6jdUxTZY1jV0xo=
=hNXm
-----END PGP SIGNATURE-----
2005-06-04 12:14:14 -08:00
mpm@selenic.com
aeaf337d80 big heap of command clean-up work
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

big heap of command clean-up work

Migrate add, forget, remove, commit, diff, addremove, tip, log,
recover, and serve.

Fix up filterfiles, relfilter, and relpath to be a bit more bulletproof

Alphabetize functions and the command table

Make everything in commands.py relative-path aware

manifest hash: f0856031a7be4e49289677b467f29bcf24ebce4a
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)

iD8DBQFCof6gywK+sNU5EO8RAoW1AJsHu8vchPSjls7wVbvsq/UKlGhqtgCgtnnl
xSBxyf/TEVWjHIk3uTa8WSE=
=YPMl
-----END PGP SIGNATURE-----
2005-06-04 11:18:56 -08:00
mpm@selenic.com
f7650114aa hg resolve: merge a given node into the working directory
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

hg resolve: merge a given node into the working directory

This is the first pass at working directory-based merges. Doing a
resolve adds a second parent to the working directory state for the
next commit.

manifest hash: 827b19995dd2d7686286da3b62c7d5fe3e0bc48c
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)

iD8DBQFCoMSHywK+sNU5EO8RAnOkAJsHH9jviMJcQJ4JurFuSlrbIwKqRACdHgNC
kkfoAxX2E5jkuOeSJ1Hjalk=
=bdrT
-----END PGP SIGNATURE-----
2005-06-03 12:58:47 -08:00
mpm@selenic.com
015cc81147 make diffdir default to dirstate.parents()
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

make diffdir default to dirstate.parents()

update various diffdir users to use default

manifest hash: aeca2b9da1aca278dd5e3f27cc2906667803577d
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)

iD8DBQFCoMPcywK+sNU5EO8RAkY8AJ90UHQXnJnkG9PJKG7IsgPeOZ2WZACgiarS
HhS2zX3TRM9WdZHo5nLvZGw=
=7YyP
-----END PGP SIGNATURE-----
2005-06-03 12:55:56 -08:00
mpm@selenic.com
f554f899b0 move repo.current to dirstate.parents()
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

move repo.current to dirstate.parents()

dirstate now tracks the parents for the working dir
add a parents command to show them

manifest hash: cd69237838c3f69f7937723c4a6803d47cb27cfa
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)

iD8DBQFCoMGuywK+sNU5EO8RAg5UAKCVLUrsJtkoIOTM+e0BLqEVN3Ni3gCeNDyy
ZF8jD728cl9K7S4sIN4gX4Y=
=P4bu
-----END PGP SIGNATURE-----
2005-06-03 12:46:38 -08:00
mpm@selenic.com
beee203034 Beginning of multi-head support
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Beginning of multi-head support

Add revlog.heads()
Add heads command to list changeset heads

manifest hash: 50df6fffe59a40c19782e2c77c8077db026fde67
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)

iD8DBQFCn7tFywK+sNU5EO8RAusWAJ9EojIxgqEEt8VZd5S+5Laj8tHV+ACfWLb5
TC7AnsoFGg50jAWF0EsofDA=
=nzyH
-----END PGP SIGNATURE-----
2005-06-02 18:07:01 -08:00
mpm@selenic.com
4a3f7fbb37 change dircache into dirstate
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

change dircache into dirstate

The dircache now tracks adds and removes directly

diffdir now makes a proper distinction between added and unknown files

Add a forget command to unadd files

Undo tries to fix up the state of just the files in the undone commit

Add and remove complain about files that are not in a proper state of
existence


manifest hash: ca0cd6abc5e119670acf11a54fefa2bc986eadf3
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)

iD8DBQFCn7TRywK+sNU5EO8RAhnSAKC2oHg1HJOCGsvpUYj4SBEq0HmuJQCgr5gl
jEBTs5AFD5IhF73YAgrcnkE=
=prQA
-----END PGP SIGNATURE-----
2005-06-02 17:39:29 -08:00
mpm@selenic.com
1f5ef11c2b hg checkout: refuse to checkout if there are outstanding changes
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

hg checkout: refuse to checkout if there are outstanding changes

This is a stop-gap until I make the working dir logic smarter

manifest hash: a3f6adcb7eecec294000039057d59771958f4186
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)

iD8DBQFCnnrKywK+sNU5EO8RAtqBAJwPQQrW5GhjMP9HMkFtfD7qhqxIcgCfXvA4
oXHO13uzBn5JOaTH3KwsMbQ=
=IzTY
-----END PGP SIGNATURE-----
2005-06-01 19:19:38 -08:00
mpm@selenic.com
dd6fb288d8 catch TERM signal in command processor
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

catch TERM signal in command processor

This keeps kill from interrupting a transaction without cleanup.

manifest hash: c50091696a3396dfed5c3168bd9e0d94c457a04b
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)

iD8DBQFCniLNywK+sNU5EO8RAvepAKCCnEX7vPheIyOu2IvV6dDahdFMWACeMih6
E2R3rA/MGACxG9HpSNH6lak=
=HR1s
-----END PGP SIGNATURE-----
2005-06-01 13:04:13 -08:00
mpm@selenic.com
f1f83067d7 commands: migrate status and branch
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

commands: migrate status and branch

manifest hash: 7d893a81a81539173fc74d86152062a1a70bed13
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)

iD8DBQFCnhESywK+sNU5EO8RAlBJAKCmv2gHefMOXfX/UUCy1tfV0cOqOQCfbeX8
oaT15B7GBL2lcalGrPXkzY8=
=8gVe
-----END PGP SIGNATURE-----
2005-06-01 11:48:34 -08:00
mpm@selenic.com
ffc0d3cdc2 commands: better argument processing, per-command help
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

commands: better argument processing, per-command help

This passes command line arguments as positional arguments rather than
as a list and attempt to catch exceptions if the arguments don't match up.

It also adds 'hg help [cmd]' which prints the syntax and docstring for
the given command.

manifest hash: cef3ac7076f99fce4265a5dc7acb57fb03d93270
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)

iD8DBQFCnghXywK+sNU5EO8RAv+5AJ9MfCCRxE+pNu3i44v5I4IyQoRaiQCeNqEK
wBzAiP+Q6F/9PL2xOrrZGHw=
=EYdk
-----END PGP SIGNATURE-----
2005-06-01 11:11:19 -08:00
mpm@selenic.com
c2d54398a7 commands: fix up some help strings
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

commands: fix up some help strings

manifest hash: e9e6061cd37d77e8061cab6a0cd3ca701e6900d7
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)

iD8DBQFCngG/ywK+sNU5EO8RAnhCAJ422e7LecJ5D/15I5PcQZxGvsgvvQCeOWIb
7LTyyAYDeht6yOQCdLWmXIE=
=bjQG
-----END PGP SIGNATURE-----
2005-06-01 10:43:11 -08:00
mpm@selenic.com
4e26999123 hg undo: fixup working dir state
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

hg undo: fixup working dir state

manifest hash: 60fd7a5621f7c4e87c7c36097aaf11b22e7ee0b4
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)

iD8DBQFCngETywK+sNU5EO8RAiC/AKChvIgy61YfOLJcTQg5BKkTLLErRgCgnJMr
+xb+XsjeNfK+83MzeuE8UOk=
=EIlj
-----END PGP SIGNATURE-----
2005-06-01 10:40:19 -08:00
mpm@selenic.com
4cc432f9f1 Beginning of new command parsing interface
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Beginning of new command parsing interface

This adds commands.py, with a primary interface dispatch(args)

Dispatch searches a table of known commands, handles switches, sets up
a repo object if appropriate, and dispatches the command.

It also handles KeyboardInterrupt and can handle similar exceptions in
the future.

If the command is unknown, it falls through to the current command handler.

Commands currently handled by the new scheme: help, init, and annotate

manifest hash: 134cd032c880985e3f92f82efb8b629dd862ba4c
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)

iD8DBQFCnXEGywK+sNU5EO8RAuDAAJ9q7K4w7qGVWv1NWjCPFGO/UJc6VQCdEhMQ
sBBlSRzah9QPy8K94catZyg=
=wuRf
-----END PGP SIGNATURE-----
2005-06-01 00:25:42 -08:00