##// END OF EJS Templates
docs/usage: fix section 'trending source files'...
Thomas De Schampheleire -
r4968:584693b3 default
parent child Browse files
Show More
@@ -1,178 +1,178 b''
1 1 .. _general:
2 2
3 3 =======================
4 4 General Kallithea usage
5 5 =======================
6 6
7 7
8 8 Repository deleting
9 9 -------------------
10 10
11 11 Currently when an admin or owner deletes a repository, Kallithea does
12 12 not physically delete said repository from the filesystem, but instead
13 13 renames it in a special way so that it is not possible to push, clone
14 14 or access the repository.
15 15
16 16 There is a special command for cleaning up such archived repos::
17 17
18 18 paster cleanup-repos --older-than=30d my.ini
19 19
20 20 This command scans for archived repositories that are older than
21 21 30 days, displays them, and asks if you want to delete them (unless given
22 22 the ``--dont-ask`` flag). If you host a large amount of repositories with
23 23 forks that are constantly being deleted, it is recommended that you run this
24 24 command via crontab.
25 25
26 26 It is worth noting that even if someone is given administrative access to
27 27 Kallithea and deletes a repository, you can easily restore such an action by
28 28 renaming the repository directory, removing the ``rm__<date>`` prefix.
29 29
30 30 File view: follow current branch
31 31 --------------------------------
32 32
33 33 In the file view, left and right arrows allow to jump to the previous and next
34 34 revision. Depending on the way revisions were created in the repository, this
35 35 could jump to a different branch. When the checkbox ``Follow current branch``
36 36 is checked, these arrows will only jump to revisions on the same branch as the
37 37 currently visible revision. So for example, if someone is viewing files in the
38 38 ``beta`` branch and marks the `Follow current branch` checkbox, the < and >
39 39 arrows will only show revisions on the ``beta`` branch.
40 40
41 41
42 42 Changelog features
43 43 ------------------
44 44
45 45 The core feature of a repository's ``changelog`` page is to show the revisions
46 46 in a repository. However, there are several other features available from the
47 47 changelog.
48 48
49 49 Branch filter
50 50 By default, the changelog shows revisions from all branches in the
51 51 repository. Use the branch filter to restrict to a given branch.
52 52
53 53 Viewing a changeset
54 54 A particular changeset can be opened by clicking on either the changeset
55 55 hash or the commit message, or by ticking the checkbox and clicking the
56 56 ``Show selected changeset`` button at the top.
57 57
58 58 Viewing all changes between two changesets
59 59 To get a list of all changesets between two selected changesets, along with
60 60 the changes in each one of them, tick the checkboxes of the first and
61 61 last changeset in the desired range and click the ``Show selected changesets``
62 62 button at the top. You can only show the range between the first and last
63 63 checkbox (no cherry-picking).
64 64
65 65 From that page, you can proceed to viewing the overall delta between the
66 66 selected changesets, by clicking the ``Compare revisions`` button.
67 67
68 68 Creating a pull request
69 69 You can create a new pull request for the changes of a particular changeset
70 70 (and its ancestors) by selecting it and clicking the ``Open new pull request
71 71 for selected changesets`` button.
72 72
73 73 Permanent repository URLs
74 74 -------------------------
75 75
76 76 Due to the complicated nature of repository grouping, URLs of repositories
77 77 can often change. For example, a repository originally accessible from::
78 78
79 79 http://server.com/repo_name
80 80
81 81 would get a new URL after moving it to test_group::
82 82
83 83 http://server.com/test_group/repo_name
84 84
85 85 Such moving of a repository to a group can be an issue for build systems and
86 86 other scripts where the repository paths are hardcoded. To mitigate this,
87 87 Kallithea provides permanent URLs using the repository ID prefixed with an
88 88 underscore. In all Kallithea URLs, for example those for the changelog and the
89 89 file view, a repository name can be replaced by this ``_ID`` string. Since IDs
90 90 are always the same, moving the repository to a different group will not affect
91 91 such URLs.
92 92
93 93 In the example, the repository could also be accessible as::
94 94
95 95 http://server.com/_<ID>
96 96
97 97 The ID of a given repository can be shown from the repository ``Summary`` page,
98 98 by selecting the ``Show by ID`` button next to ``Clone URL``.
99 99
100 100 E-mail notifications
101 101 --------------------
102 102
103 103 When the administrator correctly specified the e-mail settings in the Kallithea
104 104 configuration file, Kallithea will send e-mails on user registration and when
105 105 errors occur.
106 106
107 107 Mails are also sent for comments on changesets. In this case, an e-mail is sent
108 108 to the committer of the changeset (if known to Kallithea), to all reviewers of
109 109 the pull request (if applicable) and to all people mentioned in the comment
110 110 using @mention notation.
111 111
112 112
113 113 Trending source files
114 114 ---------------------
115 115
116 Trending source files are calculated based on a pre-defined dict of known
117 types and extensions. If you miss some extension or would like to scan some
118 custom files, it is possible to add new types in the ``LANGUAGES_EXTENSIONS_MAP`` dict
119 located in ``kallithea/lib/celerylib/tasks.py``.
116 Trending source files are calculated based on a predefined dictionary of known
117 types and extensions. If an extension is missing or you would like to scan
118 custom files, it is possible to extend the ``LANGUAGES_EXTENSIONS_MAP``
119 dictionary located in ``kallithea/config/conf.py`` with new types.
120 120
121 121
122 122 Cloning remote repositories
123 123 ---------------------------
124 124
125 125 Kallithea has the ability to clone remote repos from given remote locations.
126 126 Currently it supports the following options:
127 127
128 128 - hg -> hg clone
129 129 - svn -> hg clone
130 130 - git -> git clone
131 131
132 132
133 133 .. note:: svn -> hg cloning requires tge ``hgsubversion`` library to be installed.
134 134
135 135 If you need to clone repositories that are protected via basic auth, you
136 136 might pass the url with stored credentials inside, e.g.,
137 137 ``http://user:passw@remote.server/repo``, Kallithea will try to login and clone
138 138 using the given credentials. Please take note that they will be stored as
139 139 plaintext inside the database. Kallithea will remove auth info when showing the
140 140 clone url in summary page.
141 141
142 142
143 143
144 144 Specific features configurable in the Admin settings
145 145 ----------------------------------------------------
146 146
147 147 In general, the Admin settings should be self-explanatory and will not be
148 148 described in more detail in this documentation. However, there are a few
149 149 features that merit further explanation.
150 150
151 151 Repository extra fields
152 152 ~~~~~~~~~~~~~~~~~~~~~~~
153 153
154 154 In the `Visual` tab, there is an option `Use repository extra
155 155 fields`, which allows to set custom fields for each repository in the system.
156 156 Each new field consists of 3 attributes: ``field key``, ``field label``,
157 157 ``field description``.
158 158
159 159 Example usage of such fields would be to define company-specific information
160 160 into repositories, e.g., defining a ``repo_manager`` key that would give info
161 161 about a manager of each repository. There's no limit for adding custom fields.
162 162 Newly created fields are accessible via the API.
163 163
164 164 Meta-Tagging
165 165 ~~~~~~~~~~~~
166 166
167 167 In the `Visual` tab, option `Stylify recognised meta tags` will cause Kallithea
168 168 to turn certain meta-tags, detected in repository and repository group
169 169 descriptions, into colored tags. Currently recognised tags are::
170 170
171 171 [featured]
172 172 [stale]
173 173 [dead]
174 174 [lang => lang]
175 175 [license => License]
176 176 [requires => Repo]
177 177 [recommends => Repo]
178 178 [see => URI]
General Comments 0
You need to be logged in to leave comments. Login now