Commit Briefs

54b37e9869 Stefan Sperling

make 'got fetch' work with URLs which refer to $HOME via a tilde ~

'got clone' already happens to support such URLs via scp-style syntax: user@127.0.0.1:~/test.git While the clone operation succeded, subsequent fetch operations would raise an error: '/~/test.git' does not appear to be a git repository Make such URLs work when they are read back from got.conf, and also on the clone command line in canonical form: ssh://user@127.0.0.1/~/test.git Not adding a test case because I don't see an easy way to add test coverage for this without spilling test data into home directories or modifying ~/.ssh/ssh_config. Problem found by Jesper Wallin.


2d5ea673b3 Stefan Sperling

show path of got-fetch-http in execv error message


ad3b5b58b0 Tobias Heider

Rename got-http helper to got-fetch-http to match naming scheme.

We aren't planning to support sending anyway. ok stsp@


ced242c2eb Tobias Heider

Add initial read-only http fetch support using a got-http helper.

Currently we only support the smart protocol with a limited feature set. ok stsp@ tobhe@


7a86002db3 Omar Polo

improve execv error message

spotted using -portable on a system without openssh installed. Showing the program we've failed to exec can be handy. ok stsp@


1eb3899277 Stefan Sperling

significantly reduce the amount of code linked into gitwrapper

By moving got_serve_parse_command() from lib/serve.c into lib/dial.c as got_dial_parse_command(), we can significantly reduce the amount of symbols gitwrapper depends on indirectly. As a downside, gotsh now needs to link to dial.c. But it only uses the same parsing routine, and any other routines in dial.c would likely cause pledge violations in gotsh if used. No functional change.


6cc8a118a7 Omar Polo

dial: fix quoting for git-shell

Escape the path to the repository when connecting via SSH. This is needed if the path contains spaces, quotes or other "funny" characters, but also by git-shell which requires the argument to be surrounded by single-quote characters. Issue with git-shell reported by James Cook, fix based on an initial diff by stsp@. ok stsp@


9ea55f08a2 Omar Polo

add missing freaddrinfo

also spotted by valgrind. ok stsp@


58e31a80da Omar Polo

build with -Wwrite-strings

Throwing this into the mix for a while, we can always get rid of it again if it becomes annoying. No objections from stsp@


336075a42a Omar Polo

build with -Wmissing-prototypes

ok stsp@


805253d515 Christian Weisgerber

fix level of indirection

ok stsp


3a12860c3c Stefan Sperling

make the URI parser tolerate trailing slashes at the end of the input URI

ok naddy


c10270f60d Christian Weisgerber

assert against accidentally overflowing argv[] in got_dial_ssh()

ok stsp


5e5da8c4bc Stefan Sperling

rename got_fetch_parse_uri() to got_dial_parse_uri()

This function is now being used by both 'got fetch' and 'got send' so its former name was misleading.


d65a88a2f0 Stefan Sperling

move duplicated dial_ssh() and dial_git() functions into a common file

These functions are used by 'got send' and 'got fetch' in order to open network connections to a server. Move them into new file lib/dial.c and declare relevant functions in got_dial.h and lib/got_lib_dial.h. No functional change.