1 <?xml version="1.0" encoding="UTF-8"?>
\r
2 <!DOCTYPE sect2 SYSTEM "../../../dtd/dblite.dtd">
\r
4 <sect2 lang="en" id="git-credential-cache(1)">
\r
5 <title>git-credential-cache(1)</title>
\r
7 <primary>git-credential-cache(1)</primary>
\r
9 <simplesect id="git-credential-cache(1)__name">
\r
11 <simpara>git-credential-cache - Helper to temporarily store passwords in memory</simpara>
\r
13 <simplesect id="git-credential-cache(1)__synopsis">
\r
14 <title>SYNOPSIS</title>
\r
15 <screen>git config credential.helper 'cache [<options>]'</screen>
\r
17 <simplesect id="git-credential-cache(1)__description">
\r
18 <title>DESCRIPTION</title>
\r
19 <simpara>This command caches credentials in memory for use by future Git
\r
20 programs. The stored credentials never touch the disk, and are forgotten
\r
21 after a configurable timeout. The cache is accessible over a Unix
\r
22 domain socket, restricted to the current user by filesystem permissions.</simpara>
\r
23 <simpara>You probably don't want to invoke this command directly; it is meant to
\r
24 be used as a credential helper by other parts of Git. See
\r
25 <xref linkend="gitcredentials(7)" /> or <emphasis>EXAMPLES</emphasis> below.</simpara>
\r
27 <simplesect id="git-credential-cache(1)__options">
\r
28 <title>OPTIONS</title>
\r
32 --timeout <seconds>
\r
36 Number of seconds to cache credentials (default: 900).
\r
42 --socket <path>
\r
46 Use <emphasis><path></emphasis> to contact a running cache daemon (or start a new
\r
47 cache daemon if one is not started).
\r
48 Defaults to <emphasis>$XDG_CACHE_HOME/git/credential/socket</emphasis> unless
\r
49 <emphasis>~/.git-credential-cache/</emphasis> exists in which case
\r
50 <emphasis>~/.git-credential-cache/socket</emphasis> is used instead.
\r
51 If your home directory is on a network-mounted filesystem, you
\r
52 may need to change this to a local filesystem. You must specify
\r
59 <simplesect id="git-credential-cache(1)__controlling_the_daemon">
\r
60 <title>CONTROLLING THE DAEMON</title>
\r
61 <simpara>If you would like the daemon to exit early, forgetting all cached
\r
62 credentials before their timeout, you can issue an <emphasis>exit</emphasis> action:</simpara>
\r
63 <screen>git credential-cache exit</screen>
\r
65 <simplesect id="git-credential-cache(1)__examples">
\r
66 <title>EXAMPLES</title>
\r
67 <simpara>The point of this helper is to reduce the number of times you must type
\r
68 your username or password. For example:</simpara>
\r
69 <screen>$ git config credential.helper cache
\r
70 $ git push http://example.com/repo.git
\r
71 Username: <type your username>
\r
72 Password: <type your password>
\r
74 [work for 5 more minutes]
\r
75 $ git push http://example.com/repo.git
\r
76 [your credentials are used automatically]</screen>
\r
77 <simpara>You can provide options via the credential.helper configuration
\r
78 variable (this example drops the cache time to 5 minutes):</simpara>
\r
79 <screen>$ git config credential.helper 'cache --timeout=300'</screen>
\r
81 <simplesect id="git-credential-cache(1)__git">
\r
83 <simpara>Part of the <xref linkend="git(1)" /> suite</simpara>
\r