Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
C
cl-site
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Dave Cooper
cl-site
Commits
cc57df8f
Commit
cc57df8f
authored
6 years ago
by
Mariano Montone
Browse files
Options
Downloads
Patches
Plain Diff
Fix urls when serving
parent
a26535f7
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
Makefile
+2
-1
2 additions, 1 deletion
Makefile
layout/templates/layout_2018.html
+13
-13
13 additions, 13 deletions
layout/templates/layout_2018.html
server.py
+31
-0
31 additions, 0 deletions
server.py
with
46 additions
and
14 deletions
Makefile
+
2
−
1
View file @
cc57df8f
all
:
generate
all
:
generate
serve
:
serve
:
cd
output
;
python
-m
SimpleHTTPServer
#cd output; python -m SimpleHTTPServer
cd
output
;
python ../server.py
static
:
static
:
cp
-r
content/static output/static
cp
-r
content/static output/static
...
...
This diff is collapsed.
Click to expand it.
layout/templates/layout_2018.html
+
13
−
13
View file @
cc57df8f
...
@@ -6,14 +6,14 @@
...
@@ -6,14 +6,14 @@
<title>
{{title}}
</title>
<title>
{{title}}
</title>
<link
rel=
"stylesheet"
href=
"https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/css/bootstrap.min.css"
integrity=
"sha384-Gn5384xqQ1aoWXA+058RXPxPg6fy4IWvTNh0E263XmFcJlSAwiGgFAW/dAiS6JXm"
crossorigin=
"anonymous"
>
<link
rel=
"stylesheet"
href=
"https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/css/bootstrap.min.css"
integrity=
"sha384-Gn5384xqQ1aoWXA+058RXPxPg6fy4IWvTNh0E263XmFcJlSAwiGgFAW/dAiS6JXm"
crossorigin=
"anonymous"
>
<link
href=
"https://fonts.googleapis.com/css?family=Source+Sans+Pro:300,400,700"
rel=
"stylesheet"
type=
"text/css"
>
<link
href=
"https://fonts.googleapis.com/css?family=Source+Sans+Pro:300,400,700"
rel=
"stylesheet"
type=
"text/css"
>
<link
href=
"
./static/css
/layout_2018.css"
rel=
"stylesheet"
type=
"text/css"
>
<link
href=
"/layout_2018.css"
rel=
"stylesheet"
type=
"text/css"
>
{{#styles}}
{{#styles}}
<link
href=
"{{location}}"
rel=
"stylesheet"
type=
"text/css"
>
<link
href=
"{{location}}"
rel=
"stylesheet"
type=
"text/css"
>
{{/styles}}
{{/styles}}
</head>
</head>
<body>
<body>
<nav
class=
"navbar navbar-expand-md fixed-top navbar-dark navigation"
>
<nav
class=
"navbar navbar-expand-md fixed-top navbar-dark navigation"
>
<a
class=
"navbar-brand"
href=
"
./index.html
"
>
<a
class=
"navbar-brand"
href=
"
/
"
>
<img
width=
"30px"
height=
"30px"
<img
width=
"30px"
height=
"30px"
src=
"/static/imgs/lisplogo.png"
/>
src=
"/static/imgs/lisplogo.png"
/>
Common-Lisp.net
</a>
Common-Lisp.net
</a>
...
@@ -24,41 +24,41 @@
...
@@ -24,41 +24,41 @@
<div
class=
"collapse navbar-collapse"
id=
"navbarSupportedContent"
>
<div
class=
"collapse navbar-collapse"
id=
"navbarSupportedContent"
>
<ul
class=
"navbar-nav mr-auto"
>
<ul
class=
"navbar-nav mr-auto"
>
<li
class=
"nav-item"
>
<li
class=
"nav-item"
>
<a
class=
"nav-link"
href=
"
.
/about/"
>
About
</a>
<a
class=
"nav-link"
href=
"/about/"
>
About
</a>
</li>
</li>
<li
class=
"nav-item dropdown"
>
<li
class=
"nav-item dropdown"
>
<a
href=
"#"
class=
"nav-link dropdown-toggle"
data-toggle=
"dropdown"
>
Get started
<span
class=
"caret"
></span></a>
<a
href=
"#"
class=
"nav-link dropdown-toggle"
data-toggle=
"dropdown"
>
Get started
<span
class=
"caret"
></span></a>
<div
class=
"dropdown-menu"
role=
"menu"
>
<div
class=
"dropdown-menu"
role=
"menu"
>
<a
class=
"dropdown-item"
href=
"
.
/downloads/"
>
Download
</a>
<a
class=
"dropdown-item"
href=
"/downloads/"
>
Download
</a>
<a
class=
"dropdown-item"
href=
"
.
/tutorials/"
>
Tutorials
</a>
<a
class=
"dropdown-item"
href=
"/tutorials/"
>
Tutorials
</a>
</div>
</div>
</li>
</li>
<li
class=
"nav-item dropdown"
>
<li
class=
"nav-item dropdown"
>
<a
href=
"#"
class=
"nav-link dropdown-toggle"
data-toggle=
"dropdown"
>
Community
<span
class=
"caret"
></span></a>
<a
href=
"#"
class=
"nav-link dropdown-toggle"
data-toggle=
"dropdown"
>
Community
<span
class=
"caret"
></span></a>
<div
class=
"dropdown-menu"
role=
"menu"
>
<div
class=
"dropdown-menu"
role=
"menu"
>
<a
class=
"dropdown-item"
href=
"http://mailman.common-lisp.net/cgi-bin/mailman/listinfo"
>
Mailing lists
</a>
<a
class=
"dropdown-item"
href=
"http://mailman.common-lisp.net/cgi-bin/mailman/listinfo"
>
Mailing lists
</a>
<a
class=
"dropdown-item"
href=
"
.
/independent-lists/"
>
Independent lists
</a>
<a
class=
"dropdown-item"
href=
"/independent-lists/"
>
Independent lists
</a>
<a
class=
"dropdown-item"
href=
"
.
/orphaned-mailing-lists/"
>
Orphane lists
</a>
<a
class=
"dropdown-item"
href=
"/orphaned-mailing-lists/"
>
Orphane lists
</a>
</div>
</div>
</li>
</li>
<li
class=
"nav-item dropdown"
>
<li
class=
"nav-item dropdown"
>
<a
href=
"#"
class=
"nav-link dropdown-toggle"
data-toggle=
"dropdown"
>
Projects
<span
class=
"caret"
></span></a>
<a
href=
"#"
class=
"nav-link dropdown-toggle"
data-toggle=
"dropdown"
>
Projects
<span
class=
"caret"
></span></a>
<div
class=
"dropdown-menu"
role=
"menu"
>
<div
class=
"dropdown-menu"
role=
"menu"
>
<a
class=
"dropdown-item"
href=
"
.
/phub/"
>
Projects hub
</a>
<a
class=
"dropdown-item"
href=
"/phub/"
>
Projects hub
</a>
<a
class=
"dropdown-item"
href=
"
.
/project-intro/"
>
Hosting services
</a>
<a
class=
"dropdown-item"
href=
"/project-intro/"
>
Hosting services
</a>
<a
class=
"dropdown-item"
href=
"
.
/orphaned-projects/"
>
Orphaned projects
</a>
<a
class=
"dropdown-item"
href=
"/orphaned-projects/"
>
Orphaned projects
</a>
<a
class=
"dropdown-item"
href=
"
.
/faq/"
>
FAQ
</a>
<a
class=
"dropdown-item"
href=
"/faq/"
>
FAQ
</a>
</div>
</div>
</li>
</li>
<li
class=
"nav-item dropdown"
>
<li
class=
"nav-item dropdown"
>
<a
href=
"#"
class=
"nav-link dropdown-toggle"
data-toggle=
"dropdown"
>
Resources
<span
class=
"caret"
></span></a>
<a
href=
"#"
class=
"nav-link dropdown-toggle"
data-toggle=
"dropdown"
>
Resources
<span
class=
"caret"
></span></a>
<div
class=
"dropdown-menu"
role=
"menu"
>
<div
class=
"dropdown-menu"
role=
"menu"
>
<a
class=
"dropdown-item"
href=
"http://www.lispworks.com/documentation/lw50/CLHS/Front/Contents.htm"
>
CLHS
</a>
<a
class=
"dropdown-item"
href=
"http://www.lispworks.com/documentation/lw50/CLHS/Front/Contents.htm"
>
CLHS
</a>
<a
class=
"dropdown-item"
href=
"
.
/tools/"
>
Tools
</a>
<a
class=
"dropdown-item"
href=
"/tools/"
>
Tools
</a>
</div>
</div>
</li>
</li>
<li
class=
"nav-item"
>
<li
class=
"nav-item"
>
<a
class=
"nav-link"
href=
"
.
/contribute/"
>
Contribute
</a>
<a
class=
"nav-link"
href=
"/contribute/"
>
Contribute
</a>
</li>
</li>
</ul>
</ul>
</div>
</div>
...
...
This diff is collapsed.
Click to expand it.
server.py
0 → 100644
+
31
−
0
View file @
cc57df8f
#!/usr/bin/env python
import
SimpleHTTPServer
import
SocketServer
import
os.path
import
sys
class
MyRequestHandler
(
SimpleHTTPServer
.
SimpleHTTPRequestHandler
):
def
do_GET
(
self
):
possible_name
=
self
.
path
.
strip
(
"
/
"
)
+
'
.html
'
if
self
.
path
==
'
/
'
:
# default routing, instead of "index.html"
self
.
path
=
'
/index.html
'
elif
os
.
path
.
isfile
(
possible_name
):
# extensionless page serving
self
.
path
=
possible_name
return
SimpleHTTPServer
.
SimpleHTTPRequestHandler
.
do_GET
(
self
)
Handler
=
MyRequestHandler
port
=
8000
if
len
(
sys
.
argv
)
>
1
:
try
:
p
=
int
(
sys
.
argv
[
1
])
port
=
p
except
ValueError
:
print
"
port value provided must be an integer
"
print
"
Serving on port {0}
"
.
format
(
port
)
server
=
SocketServer
.
TCPServer
((
'
0.0.0.0
'
,
port
),
Handler
)
server
.
serve_forever
()
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment