Merge branch 'dl/credential-cache-socket-in-xdg-cache'

The default location "~/.git-credential-cache/socket" for the
socket used to communicate with the credential-cache daemon has
been moved to "~/.cache/git/credential/socket".

* dl/credential-cache-socket-in-xdg-cache:
  credential-cache: add tests for XDG functionality
  credential-cache: use XDG_CACHE_HOME for socket
  path.c: add xdg_cache_home
This commit is contained in:
Junio C Hamano
2017-03-24 13:07:34 -07:00
5 changed files with 136 additions and 5 deletions

View File

@ -1176,6 +1176,13 @@ extern int is_ntfs_dotgit(const char *name);
*/
extern char *xdg_config_home(const char *filename);
/**
* Return a newly allocated string with the evaluation of
* "$XDG_CACHE_HOME/git/$filename" if $XDG_CACHE_HOME is non-empty, otherwise
* "$HOME/.cache/git/$filename". Return NULL upon error.
*/
extern char *xdg_cache_home(const char *filename);
/* object replacement */
#define LOOKUP_REPLACE_OBJECT 1
#define LOOKUP_UNKNOWN_OBJECT 2