mirror of
https://github.com/kennethreitz/dive-into-python3.git
synced 2026-06-05 23:10:17 +00:00
css pre-flight fiddling
This commit is contained in:
+2
-2
@@ -4,10 +4,10 @@
|
||||
<meta charset=utf-8>
|
||||
<title>About the book - Dive Into Python 3</title>
|
||||
<!--[if IE]><script src=html5.js></script><![endif]-->
|
||||
<link rel=stylesheet type=text/css href=dip3.css>
|
||||
<link rel="shortcut icon" href=data:image/ico,>
|
||||
<link rel=alternate type=application/atom+xml href=http://hg.diveintopython3.org/atom-log>
|
||||
<style type=text/css>
|
||||
<link rel=stylesheet type=text/css href=dip3.css>
|
||||
<style>
|
||||
h1:before{content:""}
|
||||
</style>
|
||||
</head>
|
||||
|
||||
@@ -4,15 +4,15 @@
|
||||
<meta charset=utf-8>
|
||||
<title>Case study: porting chardet to Python 3 - Dive into Python 3</title>
|
||||
<!--[if IE]><script src=html5.js></script><![endif]-->
|
||||
<link rel=stylesheet type=text/css href=dip3.css>
|
||||
<link rel="shortcut icon" href=data:image/ico,>
|
||||
<link rel=alternate type=application/atom+xml href=http://hg.diveintopython3.org/atom-log>
|
||||
<style type=text/css>
|
||||
<link rel=stylesheet type=text/css href=dip3.css>
|
||||
<style>
|
||||
body{counter-reset:h1 20}
|
||||
</style>
|
||||
</head>
|
||||
<p class=skip><a href=#divingin>skip to main content</a>
|
||||
<form action=http://www.google.com/cse><input type=hidden name=cx value=014021643941856155761:l5eihuescdw><input type=hidden name=ie value=UTF-8> <input name=q size=31> <input type=submit name=sa value=Search></div></form>
|
||||
<form action=http://www.google.com/cse><div><input type=hidden name=cx value=014021643941856155761:l5eihuescdw><input type=hidden name=ie value=UTF-8> <input name=q size=31> <input type=submit name=sa value=Search></div></form>
|
||||
<p class=nav>You are here: <a href=/>Home</a> <span>‣</span> <a href=table-of-contents.html#case-study-porting-chardet-to-python-3>Dive Into Python 3</a> <span>‣</span>
|
||||
<h1>Case study: porting <code>chardet</code> to Python 3</h1>
|
||||
<blockquote class=q>
|
||||
|
||||
+2
-2
@@ -4,10 +4,10 @@
|
||||
<meta charset=utf-8>
|
||||
<title>Dive Into Python 3</title>
|
||||
<!--[if IE]><script src=html5.js></script><![endif]-->
|
||||
<link rel=stylesheet type=text/css href=dip3.css>
|
||||
<link rel="shortcut icon" href=data:image/ico,>
|
||||
<link rel=alternate type=application/atom+xml href=http://hg.diveintopython3.org/atom-log>
|
||||
<style type=text/css>
|
||||
<link rel=stylesheet type=text/css href=dip3.css>
|
||||
<style>
|
||||
.first{clear:both;margin-top:0;padding-top:1.75em}
|
||||
li:last-child{list-style:none;margin:0 0 0 -1.7em}
|
||||
li:last-child:before{content:"A. \00a0 \00a0"}
|
||||
|
||||
@@ -4,10 +4,10 @@
|
||||
<meta charset=utf-8>
|
||||
<title>Native datatypes - Dive into Python 3</title>
|
||||
<!--[if IE]><script src=html5.js></script><![endif]-->
|
||||
<link rel=stylesheet type=text/css href=dip3.css>
|
||||
<link rel="shortcut icon" href=data:image/ico,>
|
||||
<link rel=alternate type=application/atom+xml href=http://hg.diveintopython3.org/atom-log>
|
||||
<style type=text/css>
|
||||
<link rel=stylesheet type=text/css href=dip3.css>
|
||||
<style>
|
||||
body{counter-reset:h1 2}
|
||||
</style>
|
||||
</head>
|
||||
|
||||
@@ -4,10 +4,10 @@
|
||||
<meta charset=utf-8>
|
||||
<title>Porting code to Python 3 with 2to3 - Dive into Python 3</title>
|
||||
<!--[if IE]><script src=html5.js></script><![endif]-->
|
||||
<link rel=stylesheet type=text/css href=dip3.css>
|
||||
<link rel="shortcut icon" href=data:image/ico,>
|
||||
<link rel=alternate type=application/atom+xml href=http://hg.diveintopython3.org/atom-log>
|
||||
<style type=text/css>
|
||||
<link rel=stylesheet type=text/css href=dip3.css>
|
||||
<style>
|
||||
h1:before{counter-increment:h1;content:"Appendix A. "}
|
||||
h2:before{counter-increment:h2;content:"A." counter(h2) ". "}
|
||||
h3:before{counter-increment:h3;content:"A." counter(h2) "." counter(h3) ". "}
|
||||
|
||||
@@ -17,8 +17,10 @@ sed -i -e "s|//}.; /\* google\..*|});|g" build/dip3.js
|
||||
revision=`hg log|grep changeset|cut -d":" -f3|head -1`
|
||||
java -jar yuicompressor-2.4.2.jar build/dip3.js > build/dip3.$revision.min.js
|
||||
java -jar yuicompressor-2.4.2.jar build/dip3.css > build/dip3.$revision.min.css
|
||||
css=`cat build/dip3.$revision.min.css`
|
||||
sed -i -e "s|dip3\.js|http://wearehugh.com/dip3/dip3.${revision}.min.js|g" build/*.html
|
||||
sed -i -e "s|dip3\.css|http://wearehugh.com/dip3/dip3.${revision}.min.css|g" build/*.html
|
||||
#sed -i -e "s|dip3\.css|http://wearehugh.com/dip3/dip3.${revision}.min.css|g" build/*.html
|
||||
sed -i -e "s|<link rel=stylesheet type=text/css href=dip3.css>|<style>${css}</style>|g" -e "s|</style><style>||g" build/*.html
|
||||
sed -i -e "s|html5\.js|http://wearehugh.com/dip3/html5.js|g" build/*.html
|
||||
sed -i -e "s|=http:|=|g" build/*.html
|
||||
|
||||
@@ -26,5 +28,5 @@ sed -i -e "s|=http:|=|g" build/*.html
|
||||
chmod 644 build/*.html build/*.css build/*.js build/*.py build/*.txt build/.htaccess
|
||||
|
||||
# and push to production
|
||||
rsync -essh -avzP --delete --delete-after build/*.min.css build/*.min.js build/html5.js diveintomark.org:~/web/wearehugh.com/dip3/
|
||||
rsync -essh -avzP build/*.html build/*.py build/*.txt build/.htaccess diveintomark.org:~/web/diveintopython3.org/
|
||||
#rsync -essh -avzP --delete --delete-after build/*.min.css build/*.min.js build/html5.js diveintomark.org:~/web/wearehugh.com/dip3/
|
||||
#rsync -essh -avzP build/*.html build/*.py build/*.txt build/.htaccess diveintomark.org:~/web/diveintopython3.org/
|
||||
|
||||
@@ -4,10 +4,10 @@
|
||||
<meta charset=utf-8>
|
||||
<title>Regular expressions - Dive into Python 3</title>
|
||||
<!--[if IE]><script src=html5.js></script><![endif]-->
|
||||
<link rel=stylesheet type=text/css href=dip3.css>
|
||||
<link rel="shortcut icon" href=data:image/ico,>
|
||||
<link rel=alternate type=application/atom+xml href=http://hg.diveintopython3.org/atom-log>
|
||||
<style type=text/css>
|
||||
<link rel=stylesheet type=text/css href=dip3.css>
|
||||
<style>
|
||||
body{counter-reset:h1 4}
|
||||
</style>
|
||||
</head>
|
||||
|
||||
@@ -4,10 +4,10 @@
|
||||
<meta charset=utf-8>
|
||||
<title>Table of contents - Dive Into Python 3</title>
|
||||
<!--[if IE]><script src=html5.js></script><![endif]-->
|
||||
<link rel=stylesheet type=text/css href=dip3.css>
|
||||
<link rel="shortcut icon" href=data:image/ico,>
|
||||
<link rel=alternate type=application/atom+xml href=http://hg.diveintopython3.org/atom-log>
|
||||
<style type=text/css>
|
||||
<link rel=stylesheet type=text/css href=dip3.css>
|
||||
<style>
|
||||
h1:before{content:""}
|
||||
ol,ul{font-weight:bold}
|
||||
li ol{font-weight:normal}
|
||||
|
||||
+2
-2
@@ -4,10 +4,10 @@
|
||||
<meta charset=utf-8>
|
||||
<title>Unit testing - Dive into Python 3</title>
|
||||
<!--[if IE]><script src=html5.js></script><![endif]-->
|
||||
<link rel=stylesheet type=text/css href=dip3.css>
|
||||
<link rel="shortcut icon" href=data:image/ico,>
|
||||
<link rel=alternate type=application/atom+xml href=http://hg.diveintopython3.org/atom-log>
|
||||
<style type=text/css>
|
||||
<link rel=stylesheet type=text/css href=dip3.css>
|
||||
<style>
|
||||
body{counter-reset:h1 7}
|
||||
</style>
|
||||
</head>
|
||||
|
||||
@@ -4,10 +4,10 @@
|
||||
<meta charset=utf-8>
|
||||
<title>Your first Python program - Dive into Python 3</title>
|
||||
<!--[if IE]><script src=html5.js></script><![endif]-->
|
||||
<link rel=stylesheet type=text/css href=dip3.css>
|
||||
<link rel="shortcut icon" href=data:image/ico,>
|
||||
<link rel=alternate type=application/atom+xml href=http://hg.diveintopython3.org/atom-log>
|
||||
<style type=text/css>
|
||||
<link rel=stylesheet type=text/css href=dip3.css>
|
||||
<style>
|
||||
body{counter-reset:h1 1}
|
||||
</style>
|
||||
</head>
|
||||
|
||||
Reference in New Issue
Block a user