-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path404.html
More file actions
149 lines (137 loc) · 7.08 KB
/
404.html
File metadata and controls
149 lines (137 loc) · 7.08 KB
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
---
layout: default
permalink: /404.html
---
<style type="text/css" media="screen">
.container {
margin: 10px auto;
max-width: 600px;
text-align: center;
}
h1 {
margin: 30px 0;
font-size: 4em;
line-height: 1;
letter-spacing: -1px;
}
</style>
<div class="container">
<h1>404</h1>
<p><strong>Page not found :(</strong></p>
<p>The requested page could not be found.</p>
</div>
<script>
const url = window.location.pathname
.replace(/[/]*$/, '/');
console.log(window.location.pathname, "->", url);
const fallbackRouter = {
'/wiki/spring-documents-overview/': '/wiki/spring/document/overview/',
'/wiki/template-method-pattern/': '/wiki/pattern/template-method/',
'/wiki/design-pattern/template-method-pattern/': '/wiki/pattern/template-method/',
'/wiki/design-pattern/': '/wiki/pattern/',
'/wiki/abstract-factory-pattern/' : '/wiki/pattern/abstract-factory/',
'/wiki/design-pattern/abstract-factory-pattern/': '/wiki/pattern/abstract-factory/',
'/wiki/adapter-pattern/' : '/wiki/pattern/adapter/',
'/wiki/design-pattern/adapter-pattern/': '/wiki/pattern/adapter/',
'/wiki/builder-pattern/' : '/wiki/pattern/builder/',
'/wiki/design-pattern/builder-pattern/' : '/wiki/pattern/builder/',
'/wiki/strategy-pattern/' : '/wiki/pattern/strategy/',
'/wiki/design-pattern/strategy-pattern/' : '/wiki/pattern/strategy/',
'/wiki/strangler-pattern/': '/wiki/pattern/strangler/',
'/wiki/command-pattern/': '/wiki/pattern/command/',
'/wiki/controller-pattern/': '/wiki/pattern/controller/',
'/wiki/design-pattern-quotes/': '/wiki/pattern/quotes/',
'/wiki/decorator-pattern/': '/wiki/pattern/decorator/',
'/wiki/factory-method-pattern/': '/wiki/pattern/factory-method/',
'/wiki/null-object-pattern/': '/wiki/pattern/null-object/',
'/wiki/observer-pattern/': '/wiki/pattern/observer/',
'/wiki/static-factory-method-pattern/': '/wiki/pattern/static-factory-method/',
'/wiki/programming-language/': '/wiki/language/',
'/wiki/java-exception-handling/': '/wiki/java/exception-handling/',
'/wiki/Object-equals/': '/wiki/java/object-equals/',
'/wiki/gerald-weinberg-language-king/': '/wiki/people/gerald-weinberg/',
'/wiki/java-stream/': '/wiki/java/stream/',
'/wiki/ronald-wayne/': '/wiki/people/ronald-wayne/',
'/wiki/man-cmd/': '/wiki/cmd/man/',
'/wiki/two-eggs-100-floor/': '/wiki/problem/two-eggs-100-floor/',
'/wiki/ag/': '/wiki/cmd/ag/',
'/wiki/curl/': '/wiki/cmd/curl/',
'/wiki/proverb/': '/wiki/jargon/',
'/wiki/vim-auto-completion/': '/wiki/vim/auto-completion/',
'/wiki/mv-cmd/': '/wiki/cmd/mv/',
'/wiki/git-index/': '/wiki/git/index/',
'/wiki/sed/': '/wiki/cmd/sed/',
'/wiki/git-chagne-hundreds-commit-messages/': '/wiki/git/examples/',
'/wiki/git-checkout-specific-files/': '/wiki/git/examples/',
'/wiki/java-javadoc/': '/wiki/java/javadoc/',
'/wiki/java-util-arraylist/': '/wiki/java/arraylist/',
'/wiki/fc/': '/wiki/cmd/fc/',
'/wiki/openssl/': '/wiki/cmd/openssl/',
'/wiki/TOML/': '/wiki/language/toml/',
'/wiki/clojure/study/PersistentList/': '/wiki/clojure/study/persistent-list/',
'/wiki/tr-cmd/': '/wiki/cmd/tr/',
'/wiki/find-cmd/': '/wiki/cmd/find/',
'/wiki/java8/': '/wiki/java/8/',
'/wiki/clojure/study/persistent-map/': '/wiki/clojure/study/map/',
'/wiki/cal-cmd/': '/wiki/cmd/cal/',
'/wiki/ditto-cmd/': '/wiki/cmd/ditto/',
'/wiki/links-2019/': '/wiki/links/2019/',
'/wiki/links-2018/': '/wiki/links/2018/',
'/wiki/ultisnips/': '/wiki/vim/ultisnips/',
'/wiki/clojure/threading-macros/': '/wiki/clojure/guide/threading-macros/',
'/wiki/date-cmd/': '/wiki/cmd/date/',
'/wiki/tree-cmd/': '/wiki/cmd/tree/',
'/wiki/vim-persistent-undo/': '/wiki/vim/persistent-undo/',
'/wiki/git-log/': '/wiki/git/log/',
'/wiki/vim-coc/': '/wiki/vim/coc-nvim/',
'/wiki/less-cmd/': '/wiki/cmd/less/',
'/wiki/Python3/': '/wiki/python/',
'/wiki/Object-hashCode/': '/wiki/java/object-hashcode/',
'/wiki/Golang/': '/wiki/go/',
'/wiki/study-note/': '/wiki/study/note/',
'/wiki/study-data-intensive-application/': '/wiki/study/ddia/',
'/wiki/book-lyubishev/': '/wiki/book/lyubishev/',
'/wiki/The-Jargon-File/': '/wiki/book/the-jargon-file/',
'/wiki/vim-configure-split/': '/wiki/vim/configure-split/',
'/wiki/vim-rest-console/': '/wiki/vim/rest-console/',
'/wiki/vim-with-space-char/': '/wiki/vim/set-empty-chars/',
'/wiki/bat-cmd/': '/wiki/cmd/bat/',
'/wiki/airplain-rule/': '/wiki/jargon/airplane-rule/',
'/wiki/java-enum/': '/wiki/java/enum/',
'/wiki/Object-toString/': '/wiki/java/object-tostring/',
'/wiki/two-n-base-converting/': '/wiki/math/two-n-base-converting/',
'/wiki/scrum/': '/wiki/software-engineering/scrum/',
'/wiki/kanban/': '/wiki/software-engineering/kanban/',
'/wiki/bootstrapping/': '/wiki/jargon/bootstrapping/',
'/wiki/migrate-to-new-macbook/': '/wiki/mac/setting/',
'/wiki/yes-cmd/': '/wiki/cmd/yes/',
'/wiki/brew/': '/wiki/cmd/brew/',
'/wiki/vim-conceallevel/': '/wiki/vim/conceallevel/',
'/wiki/Bill-Atkinson-productivity/': '/wiki/people/bill-atkinson/',
'/wiki/file-cmd/': '/wiki/cmd/file/',
'/wiki/Postel-s-law/': '/wiki/jargon/postel-s-law/',
'/wiki/Edsel-edict/': '/wiki/jargon/edsel-edict/',
'/wiki/metcalfe-s-law/': '/wiki/jargon/metcalfe-s-law/',
'/wiki/SOLID/': '/wiki/jargon/solid/',
'/wiki/start-rust-with-vim/': '/wiki/rust/vim-setting/',
'/wiki/basename/': '/wiki/cmd/basename/',
'/wiki/java-enhancements/': '/wiki/java/enhancements/',
'/wiki/email-validation/': '/wiki/regex/email-validation/',
'/wiki/regex-prime/': '/wiki/regex/prime-number/',
'/wiki/egyptian-multiplication/': '/wiki/algorithm/egyptian-multiplication/',
'/wiki/article/vim-night/2022-03-31-insert-mode/': '/wiki/article/vim-night/20220331-insert-mode/',
'/wiki/article/vim-night/2022-03-27-ultisnips/': '/wiki/article/vim-night/20220327-ultisnips/',
'/wiki/java_home/': '/wiki/cmd/java_home/',
'/wiki/gc-death-spiral/': '/wiki/java/gc/death-spiral/',
'/wiki/hofstadter-s-law/': '/wiki/jargon/hofstadter-s-law/',
'/wiki/dc-cmd/': '/wiki/cmd/dc/',
'/wiki/java-optional/': '/wiki/java/optional/',
'/wiki/java8-performance-improvement-for-hashmap/': '/wiki/java/hashmap/',
'/wiki/strfile-cmd/': '/wiki/cmd/strfile/',
'/wiki/ACID/': '/wiki/database/acid/',
'/wiki/jargon/acid/': '/wiki/database/acid/',
};
if (fallbackRouter[url]) {
window.location.href = fallbackRouter[url].concat(window.location.hash);
}
</script>