Commit graph

68 commits

Author SHA1 Message Date
Sitaram Chamarty b5024027ca yaaay! http is finally done! 2012-04-15 21:14:56 +05:30
Sitaram Chamarty d3610191d3 supporting DOS and fake Unix...
I was very, very, tempted to say "sorry; not supported".  Sadly,
prudence won over juvenile glee...

PS: DOS == dominant operating system
2012-04-06 21:13:56 +05:30
Sitaram Chamarty e1c7e546aa cpu-time command -> CpuTime trigger module...
...now that triggers are not restricted to external programs and can be
perl code called by gitolite-shell (thus in the same PID), there's no
need to compute and pass along the times() array.

This also changes the arguments to POST_GIT; they're now the same as
PRE_GIT's.
2012-04-06 17:26:27 +05:30
Sitaram Chamarty 7c6728af89 (some minor changes)
- whitespace change to t/reset
  - remove dbg line accidentally left in in Load.pm
  - add a bit more explanation to 'writable'
2012-04-05 21:31:59 +05:30
gitolite tester 25bb1c00db mirroring without sausages
(or at least without showing the making of said sausages)
2012-04-02 13:18:30 +05:30
Sitaram Chamarty 2c1f46c055 %HOSTNAME and new subconf enhancement 2012-03-30 23:08:53 +05:30
Sitaram Chamarty 906ed4cbe2 logging, tracing, and perltidy, ...
...plus renamed a couple of log events for consistency
2012-03-30 23:07:46 +05:30
Sitaram Chamarty dfb9844dfb info command simplified
(thanks to Eli for the back-and-forth that led to this)
2012-03-30 22:57:06 +05:30
Sitaram Chamarty 5db29062f5 try: info command header enhanced 2012-03-28 15:31:31 +05:30
Sitaram Chamarty 2bec551009 'writes' -> 'writable', order of arguments changed 2012-03-27 19:42:30 +05:30
Sitaram Chamarty 61f6967f67 partial-copy fixed...
...there was one real bug, plus I had forgotten to put a comented out
line in the rc file, but most of the rest of the effort was moving the
test script over.

oh and I'd also forgotten to move this from 'commands' to 'triggers' :-)
2012-03-26 21:27:49 +05:30
Sitaram Chamarty 07cf7fedfe move triggers into their own subdir...
...otherwise 'gitolite help' was getting too confusing, mixing up stuff
that users should not be running directly (even on the server)

----

implementation notes:

those who are worried about the '../triggers/' in various parts of the
code here, remember you can only do that from a command line on the
server.  Remote users can only use commands that have been explicitly
listed in the COMMANDS hash in the rc file.  This means they can't even
access other commands in the same directory as, say, the 'info' command,
so a '../' is definitely not going to work.
2012-03-26 11:02:57 +05:30
Sitaram Chamarty 96ccbf0c1c make standalone config entries work
For example, in

    repo foo/..*
        C   =   u1 u2 u3
        RW+ =   CREATOR
        RW  =   WRITERS
        R   =   READERS

        config hooks.emailprefix = '[%GL_REPO] '
        config foo.bar  = bar one

    repo foo/u1/..*
        config bar.baz  = frob nitz

make that last config also work!
2012-03-26 05:54:17 +05:30
Sitaram Chamarty 2845de74ea Easy.pm learns config(), acquires a test script 2012-03-25 19:31:01 +05:30
Sitaram Chamarty cb9794d55b warn about test suite clobbering lots of stuff
(not just ~/.ssh!)
2012-03-25 11:07:11 +05:30
Sitaram Chamarty 35ec0cf927 renamed ssh tests to prevent accidents to ~/.ssh 2012-03-24 10:30:46 +05:30
Sitaram Chamarty 1c590e633f run compat checks when old rc found
(also removed legacy-delegation sugar script)
2012-03-24 10:30:45 +05:30
Sitaram Chamarty 8dc43affdb minor changes to testing setup 2012-03-24 10:30:45 +05:30
Sitaram Chamarty 938acc589f test daemon/gitweb updates by setting perms 2012-03-24 10:30:45 +05:30
Sitaram Chamarty 320356d66c cleaned up logging quite a bit; details:
- a remote "id" (usually the IP) is generated and logged on the first
    log message in a "transaction"

  - speaking of which, a new "transaction ID" is logged that stays the
    same for each input command/invocation, tying together all the
    spawned commands

  - so now time stamps can be generated each time they are needed,
    rather than re-use the one at the beginning

  - log messages have a keyword at the start now
        remote, (create), check1 -- from gitolite-shell
        update, check2 -- from update
        post-up -- from post-update
        command -- from gitolite
        die, system -- from anywhere
2012-03-24 10:30:45 +05:30
Sitaram Chamarty bb9f045ec3 trigger POST_CREATE from user actions
- uncomment the POST_CREATE section in rc by default now
  - have perms call 'gitolite trigger POST_CREATE'
2012-03-24 10:30:45 +05:30
Sitaram Chamarty 98a6b08ff4 'desc' command added (manually smoke tested only; no test script) 2012-03-24 10:30:45 +05:30
Sitaram Chamarty 80a234c0f6 upgraded the basic test a bit for quicker turnaround on some experiments 2012-03-24 10:30:45 +05:30
Sitaram Chamarty 661fefbd0e added more personal branch tests 2012-03-24 10:30:45 +05:30
Sitaram Chamarty 139c08d3a1 abort on suspicious ref names
(and the other Dan Carpenter finding too, while we're about it!)

Note that neither of these is an actual issue, (and even less likely now
that gitolite is pure perl and no shell metas used) but it's just
playing safe.
2012-03-24 10:30:45 +05:30
Sitaram Chamarty 999f9cd39d make site-local scripts easier to write
- new Gitolite::Easy module hides all the other stuff
  - (put GL_ADMIN_BASE and GL_REPO_BASE into %ENV)
  - new 'gitolite creator' shell command
  - 'writes' command modified to use Gitolite::Easy.  It is also the
    only dual mode command -- it can be invoked remotely as well as
    locally.  I deem that the required trick to make other remote-only
    commands work locally is too much trouble for what is probably a
    rarely used command.
2012-03-24 10:30:45 +05:30
Sitaram Chamarty 5deafb6823 fix some "this specific user" dependencies for testing 2012-03-24 10:30:45 +05:30
Sitaram Chamarty 43f95f9b22 (minor) help command usage message changed 2012-03-24 10:30:45 +05:30
Sitaram Chamarty f0355d749b 'gitolite writes off/on...' done 2012-03-24 10:30:45 +05:30
Sitaram Chamarty 1ec8be663e (test infrastructure) CLONE/PUSH macros redefined 2012-03-24 10:30:45 +05:30
Sitaram Chamarty 1de773ab8e perm-roles.t 2012-03-24 10:30:44 +05:30
Sitaram Chamarty a6d8184a56 rule sequences test 2012-03-24 10:30:44 +05:30
Sitaram Chamarty 545c00aa26 perms with groups test 2012-03-24 10:30:44 +05:30
Sitaram Chamarty 741512482b 'info' learned not to show ^C column when used with '-p' 2012-03-24 10:30:44 +05:30
Sitaram Chamarty 9f1e360ef3 deny-create test (the RWC stuff) 2012-03-24 10:30:44 +05:30
Sitaram Chamarty 0614655252 (minor) sequence.t 2012-03-24 10:30:44 +05:30
Sitaram Chamarty 32494cfa0c info learned '-p' and pattern limiting.
'-p' is what gives you 'expand' now
2012-03-24 10:30:44 +05:30
Sitaram Chamarty 5b5c02f226 merge-check test 2012-03-24 10:30:44 +05:30
Sitaram Chamarty af11919025 git-configs update code done 2012-03-24 10:30:44 +05:30
Sitaram Chamarty 7b1efe8a7b (minor) 2012-03-24 10:30:44 +05:30
Sitaram Chamarty e6ba17fc52 "deny-rules" (used to be called "deny-repo" in g2) 2012-03-24 10:30:44 +05:30
Sitaram Chamarty b1a75b7889 gitweb/daemon post-create scripts done 2012-03-24 10:30:44 +05:30
Sitaram Chamarty 80b50f3be8 added delegation tests
(although one seems almost the same as the other...)
2012-03-24 10:30:44 +05:30
Sitaram Chamarty 20fd0d0c19 (minor) test reformatting 2012-03-24 10:30:44 +05:30
Sitaram Chamarty 2069156c6b wild repos test #2 2012-03-24 10:30:43 +05:30
Sitaram Chamarty c79f9d2381 glt learns to deal better with non-git commands 2012-03-24 10:30:43 +05:30
Sitaram Chamarty e743cab1a3 perms command done (smoke tested) 2012-03-24 10:30:43 +05:30
Sitaram Chamarty 3c5ae7f26b added 'RW+CDM' perm function, including some test code for 'D' 2012-03-24 10:30:43 +05:30
Sitaram Chamarty d5ddf6c68d wip test suite 2012-03-24 10:30:43 +05:30
Sitaram Chamarty 44e6bc4bb2 logging (but see below)
The logging is both for paranoia and parsing/automated processing.  The
ones you're probably interested in parsing should be easy to pick out
and are very likely to have tab-delimited fields already.
2012-03-24 10:30:43 +05:30