/
about_search.html
183 lines (140 loc) · 5.21 KB
/
about_search.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
<html>
<head>
<title>Help on Find</title>
<link rel="stylesheet" type="text/css" href="color_styles.css" />
</head>
<style>
body{
font-family: Arial;
font-size: 12pt;
background-color: var(--body-background);
color: var(--body-text);
}
h4{
text-align:left;
}
h2, h3{
text-align:center;
}
code{
color: var(--code-text);
font-size: 11pt;
}
th{
border-collapse: collapse;
text-align:left;
font-size: 12pt;
padding: 6px;
}
table{
border-collapse: collapse;
text-align:left;
}
tr{
border-bottom: 2px solid #ccc;
font-size: 10pt;
}
td{
padding: 6px;
}
img[src="images/Cheat-sheet-search.png"],
img[src="images/searched_status_bar.png"]
{
filter: invert( 0% );
}
</style>
<!-- https://www.w3schools.com/howto/howto_js_collapsible.asp -->
<style>
.collapsible {
background-color: var(--body-background);
color: var(--body-text);
cursor: pointer;
padding: 8px;
width: 100%;
border: none;
text-align: left;
outline: none;
font-size: 15px;
}
.active, .collapsible:hover {
//background-color: #555;
}
.collapsible:after {
content: '\002B'; # Unicode character for "plus" sign (+)
//color: white;
font-weight: bold;
float: left;
margin-left: 5px;
}
.active:after {
content: "\2212"; # Unicode character for "plus" sign (-)
}
.content {
padding: 0 18px;
max-height: 0;
overflow: hidden;
transition: max-height 0.2s ease-out;
}
.quickUnfold {
transition: max-height 0.0s ease-out;
}
</style>
<body class='light'>
<!-- Dark mode on/off , zoom -->
<script>
if (global.localState.dark){
document.body.classList.add('dark');
}
window.document.body.style.zoom = global.state.zoom;
</script>
<div id="search-content">
<div id="search-inner-content" style="height: auto;">
<!-------------------------------------------------------------------------------------------->
<h4 id="SEARCH">Searching history </h4>
<p>The number of visible previous commits can be filtered in a dialog that opens
by clicking the <img src="images/find_black.png" height="17" width="17"> icon.
</p>
<p>The dialog allows filtering using a combination of the fields for :
<ul>
<li>file name (part of, or whole name)</li>
<li>text in commit message</li>
<li>changed code lines in which search term exists (see below)</li>
<li>date range</li>
</ul>
</p>
<i>Figure showing the dialog :<br></i>
<br>
<img class="image_background" style='vertical-align:middle;' src="images/Cheat-sheet-search.png" width="65%">
<br>
<br>
<p>
After pressing the [Find] button, the lower status bar shows something like <code>(1 of 2)</code>, where the second number shows how
many commits that were found, and the first number which of these commits is currently displayed. This filtered history
can be browsed by the arrow buttons
(<img src="images/up-arrow_hover.png" height="17" width="17">
<img src="images/down-arrow_hover.png" height="17" width="17">),
exactly as described for the non-filtered history. The "abbreviated hash" code of the commit is also shown at the bottom.
</p>
<i>Figure showing the lower status-bar after search :<br></i>
<br>
<img style='vertical-align:middle;' src="images/searched_status_bar.png" width="65%">
<br>
<br>
<p>
The format for dates follow git notation, and can be in many convenient formats as indicated in above figure text. Git uses
a library called "approxidate", which is very flexible, but the documentation is sparse.
</p>
<p>
Code search finds commits, by looking for lines that has changed and that contain the search text.
Thus the search text does not have to be changed, but a modified line must contain the word searched for.
</p>
<p>
The filter is disabled by clicking the <img src="images/find_black.png" height="17" width="17"> icon again.
</p>
<br>
<br>
<!-------------------------------------------------------------------------------------------->
</div>
</div>
</body>
</html>