You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
<p>This is the server software that runs on <a href="https://cors.isomorphic-git.org">https://cors.isomorphic-git.org</a>
67
-
– a free service (generously sponsored by <a href="https://www.clever-cloud.com/?utm_source=ref&utm_medium=link&utm_campaign=isomorphic-git">Clever Cloud</a>)
68
-
for users of <a href="https://isomorphic-git.org">isomorphic-git</a> that enables cloning and pushing repos in the browser.</p>
69
-
<p>The source code is hosted on Github at <a href="https://github.com/isomorphic-git/cors-proxy">https://github.com/isomorphic-git/cors-proxy</a></p>
70
-
<p>It can also be installed from npm with <code>npm install <a href="https://npmjs.org/package/${pkg.name}">@isomorphic-git/cors-proxy</a></code></p>
71
-
72
-
<h2>Terms of Use</h2>
73
-
<p><b>This free service is provided to you AS IS with no guarantees.
74
-
By using this free service, you promise not to use excessive amounts of bandwidth.
75
-
</b></p>
76
-
77
-
<p><b>If you are cloning or pushing large amounts of data your IP address may be banned.
78
-
Please run your own instance of the software if you need to make heavy use this service.</b></p>
79
-
80
-
<h2>Allowed Origins</h2>
81
-
This proxy allows git clone / fetch / push / getRemoteInfo requests from these domains: <code>${process.env.ALLOW_ORIGIN||'*'}</code>
82
-
</html>
83
-
`
84
-
returnsend(res,400,html)
85
-
}
10
+
middleware(req,res,()=>{
11
+
letu=url.parse(req.url,true)
12
+
13
+
if(u.pathname==='/'){
14
+
res.setHeader('content-type','text/html')
15
+
lethtml=`<!DOCTYPE html>
16
+
<html>
17
+
<title>@isomorphic-git/cors-proxy</title>
18
+
<h1>@isomorphic-git/cors-proxy</h1>
19
+
<p>This is the server software that runs on <a href="https://cors.isomorphic-git.org">https://cors.isomorphic-git.org</a>
20
+
– a free service (generously sponsored by <a href="https://www.clever-cloud.com/?utm_source=ref&utm_medium=link&utm_campaign=isomorphic-git">Clever Cloud</a>)
21
+
for users of <a href="https://isomorphic-git.org">isomorphic-git</a> that enables cloning and pushing repos in the browser.</p>
22
+
<p>The source code is hosted on Github at <a href="https://github.com/isomorphic-git/cors-proxy">https://github.com/isomorphic-git/cors-proxy</a></p>
23
+
<p>It can also be installed from npm with <code>npm install <a href="https://npmjs.org/package/${pkg.name}">@isomorphic-git/cors-proxy</a></code></p>
24
+
25
+
<h2>Terms of Use</h2>
26
+
<p><b>This free service is provided to you AS IS with no guarantees.
27
+
By using this free service, you promise not to use excessive amounts of bandwidth.
28
+
</b></p>
29
+
30
+
<p><b>If you are cloning or pushing large amounts of data your IP address may be banned.
31
+
Please run your own instance of the software if you need to make heavy use this service.</b></p>
32
+
33
+
<h2>Allowed Origins</h2>
34
+
This proxy allows git clone / fetch / push / getRemoteInfo requests from these domains: <code>${process.env.ALLOW_ORIGIN||'*'}</code>
0 commit comments