Skip to content

Commit

Permalink
test amazon s3 start
Browse files Browse the repository at this point in the history
  • Loading branch information
studiomohawk committed Mar 13, 2011
1 parent f64f807 commit be29e38
Show file tree
Hide file tree
Showing 81 changed files with 1,913 additions and 1,720 deletions.
237 changes: 237 additions & 0 deletions .htaccess
Original file line number Diff line number Diff line change
@@ -0,0 +1,237 @@
# Apache configuration file
# httpd.apache.org/docs/2.2/mod/quickreference.html

# Note .htaccess files are an overhead, this logic should be in your Apache config if possible
# httpd.apache.org/docs/2.2/howto/htaccess.html

# Techniques in here adapted from all over, including:
# Kroc Camen: camendesign.com/.htaccess
# perishablepress.com/press/2006/01/10/stupid-htaccess-tricks/


# Force the latest IE version, in various cases when it may fall back to IE7 mode
# github.com/rails/rails/commit/123eb25#commitcomment-118920
# Use ChromeFrame if it's installed for a better experience for the poor IE folk
<IfModule mod_setenvif.c>
<IfModule mod_headers.c>
BrowserMatch MSIE ie
Header set X-UA-Compatible "IE=Edge,chrome=1" env=ie
</IfModule>
</IfModule>

<IfModule mod_headers.c>
# Because X-UA-Compatible isn't sent to non-IE (to save header bytes),
# We need to inform proxies that content changes based on UA
Header append Vary User-Agent
# Cache control is set only if mod_headers is enabled, so that's unncessary to declare
</IfModule>

# Serve cross-domain ajax requests, disabled.
# enable-cors.org
# code.google.com/p/html5security/wiki/CrossOriginRequestSecurity
# <IfModule mod_headers.c>
# Header set Access-Control-Allow-Origin "*"
# </IfModule>




# allow access from all domains for webfonts
# alternatively you could only whitelist
# your subdomains like "sub.domain.com"

<FilesMatch "\.(ttf|otf|eot|woff|font.css)$">
<IfModule mod_headers.c>
Header set Access-Control-Allow-Origin "*"
</IfModule>
</FilesMatch>


# audio
AddType audio/ogg oga ogg

# video
AddType video/ogg ogv
AddType video/mp4 mp4
AddType video/webm webm

# Proper svg serving. Required for svg webfonts on iPad
# twitter.com/FontSquirrel/status/14855840545
AddType image/svg+xml svg svgz
AddEncoding gzip svgz

# webfonts
AddType application/vnd.ms-fontobject eot
AddType font/truetype ttf
AddType font/opentype otf
AddType font/woff woff

# assorted types
AddType image/vnd.microsoft.icon ico
AddType image/webp webp
AddType text/cache-manifest manifest
AddType text/x-component htc
AddType application/x-chrome-extension crx
AddType application/x-xpinstall xpi
AddType application/octet-stream safariextz



# allow concatenation from within specific js and css files

# e.g. Inside of script.combined.js you could have
# <!--#include file="jquery-1.4.4.js" -->
# <!--#include file="jquery.idletimer.js" -->
# and they would be included into this single file

# this is not in use in the boilerplate as it stands. you may
# choose to name your files in this way for this advantage
# or concatenate and minify them manually.
# Disabled by default.

# <FilesMatch "\.combined\.(js|css)$">
# Options +Includes
# SetOutputFilter INCLUDES
# </FilesMatch>





# gzip compression.
<IfModule mod_deflate.c>

# html, txt, css, js, json, xml, htc:
<IfModule filter_module>
FilterDeclare COMPRESS
FilterProvider COMPRESS DEFLATE resp=Content-Type /text/(html|css|javascript|plain|x(ml|-component))/
FilterProvider COMPRESS DEFLATE resp=Content-Type /application/(javascript|json|xml|x-javascript)/
FilterChain COMPRESS
FilterProtocol COMPRESS change=yes;byteranges=no
</IfModule>

<IfModule !mod_filter.c>
# Legacy versions of Apache
AddOutputFilterByType DEFLATE text/html text/plain text/css application/json
AddOutputFilterByType DEFLATE text/javascript application/javascript application/x-javascript
AddOutputFilterByType DEFLATE text/xml application/xml text/x-component
</IfModule>

# webfonts and svg:
<FilesMatch "\.(ttf|otf|eot|svg)$" >
SetOutputFilter DEFLATE
</FilesMatch>
</IfModule>



# these are pretty far-future expires headers
# they assume you control versioning with cachebusting query params like
# <script src="application.js?20100608">
# additionally, consider that outdated proxies may miscache
# www.stevesouders.com/blog/2008/08/23/revving-filenames-dont-use-querystring/

# if you don't use filenames to version, lower the css and js to something like
# "access plus 1 week" or so

<IfModule mod_expires.c>
ExpiresActive on

# Perhaps better to whitelist expires rules? Perhaps.
ExpiresDefault "access plus 1 month"

# cache.manifest needs re-requests in FF 3.6 (thx Remy ~Introducing HTML5)
ExpiresByType text/cache-manifest "access plus 0 seconds"

# your document html
ExpiresByType text/html "access plus 0 seconds"

# data
ExpiresByType text/xml "access plus 0 seconds"
ExpiresByType application/xml "access plus 0 seconds"
ExpiresByType application/json "access plus 0 seconds"


# rss feed
ExpiresByType application/rss+xml "access plus 1 hour"

# favicon (cannot be renamed)
ExpiresByType image/vnd.microsoft.icon "access plus 1 week"

# media: images, video, audio
ExpiresByType image/gif "access plus 1 month"
ExpiresByType image/png "access plus 1 month"
ExpiresByType image/jpg "access plus 1 month"
ExpiresByType image/jpeg "access plus 1 month"
ExpiresByType video/ogg "access plus 1 month"
ExpiresByType audio/ogg "access plus 1 month"
ExpiresByType video/mp4 "access plus 1 month"
ExpiresByType video/webm "access plus 1 month"

# webfonts
ExpiresByType font/truetype "access plus 1 month"
ExpiresByType font/opentype "access plus 1 month"
ExpiresByType font/woff "access plus 1 month"
ExpiresByType image/svg+xml "access plus 1 month"
ExpiresByType application/vnd.ms-fontobject "access plus 1 month"

# css and javascript
ExpiresByType text/css "access plus 1 month"
ExpiresByType application/javascript "access plus 1 month"
ExpiresByType text/javascript "access plus 1 month"

Header append Cache-Control "public"
</IfModule>




# Since we're sending far-future expires, we don't need ETags for
# static content.
# developer.yahoo.com/performance/rules.html#etags
FileETag None




# Allow cookies to be set from iframes (for IE only)
# If needed, uncomment and specify a path or regex in the Location directive

# <IfModule mod_headers.c>
# <Location />
# Header set P3P "policyref=\"/w3c/p3p.xml\", CP=\"IDC DSP COR ADM DEVi TAIi PSA PSD IVAi IVDi CONi HIS OUR IND CNT\""
# </Location>
# </IfModule>


# you probably want www.example.com to forward to example.com -- shorter URLs are sexier.
# no-www.org/faq.php?q=class_b
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{HTTPS} !=on
RewriteCond %{HTTP_HOST} ^www\.(.+)$ [NC]
RewriteRule ^(.*)$ http://%1/$1 [R=301,L]
</IfModule>

# without -MultiViews, Apache will give a 404 for a rewrite if a folder of the same name does not exist
# e.g. /blog/hello : webmasterworld.com/apache/3808792.htm
Options -MultiViews
# -Indexes will have Apache block users from browsing folders without a default document
# Options -Indexes



# custom 404 page
ErrorDocument 404 /404/index.html



# use utf-8 encoding for anything served text/plain or text/html
AddDefaultCharset utf-8
# force utf-8 for a number of file formats
AddCharset utf-8 .html .css .js .xml .json .rss



# We don't need to tell everyone we're apache.
ServerSignature Off
36 changes: 36 additions & 0 deletions 404.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
---
layout: nil
title: 404 - Not Found
desctiption: CSS Radarへの記事のリクエストはTwitterで受け付けています
---
{% include system_head.html %}
<body class="{{ page.layout }}">
<div id="page">
{% include header.html %}
<div id="main" role="main">
<article class="the-article">
<div class="article-inner">
<div class="content">
<header>
<div class="head-inner">
<h1>{{ page.title }}</h1>
</div>
</header>
<div class="bd">
<p>記事のリクエストは<a href="http://twitter.com/#!/cssradar">Twitter @ cssradar</a>まで</p>
<h2>Recent Articles</h2>
<ul class="recent">
{% for post in site.posts limit:10 %}
<li><a href="{{ post.url }}" title="{{ post.title }}">{{ post.title }}</a></li>
{% endfor %}
</ul>
</div>
</div>
</div>
</article>
</div><!-- id="main" -->
{% include footer.html %}
</div><!-- id="page" -->
{% include system_foot.html %}
</body>
</html>
2 changes: 2 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
The MIT License

Copyright (c) 2011 Yuya Saito

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the 'Software'), to deal
in the Software without restriction, including without limitation the rights
Expand Down
2 changes: 0 additions & 2 deletions README.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -25,5 +25,3 @@ I plan to publish my themes on github so you can use Issue page on github to sug
I have repository for this blog at [github](https://github.com/studiomohawk/_layouts). you can fork me.

You can follow me [@cssrader](http://twitter.com/#!/cssradar)

If you like what I'm doing you could give me an invite for <del>[Forrest](http://forrst.com)</del>(I've got it. Thanks!) or [Dribbble](http://dribbble.com).
8 changes: 8 additions & 0 deletions Rakefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
require 'juicer'

namespace :juicer do
desc 'Merges stylesheets'
task :css do
sh 'juicer merge --force _site/css/master.css'
end
end
22 changes: 11 additions & 11 deletions _config.yml
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
#Presentation Settings
sitename: _layouts
tagline: themes for jekyll
url: http://layouts.studiomohawk.com
#Deployment Settings
# MUST EDIT BELOW
sitename: the_minimum #Your site title
tagline: themes for jekyll #You should always have a tagline
url: http://your.site.com #URL Please
ga: UA-XXXXX-X #Google Analytics ID
sitemap: GOOGLEWEBMASTER #Google webmaster verification code
# END
# CHOOSE YOUR PREFERENCE
pygments: true
markdown: kramdown
markdown: maruku
permalink: pretty
kramdown:
auto_ids: false
exclude: LICENSE, README.markdown
ftp_host: studiomohawk.com
ftp_dir: /www/layouts
# END
exclude: LICENSE, README.markdown, Rakefile
4 changes: 2 additions & 2 deletions _includes/about.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<h4>about</h4>
<p>
<a href="http://layouts.studiomohawk.com">_layouts</a> is a theme gallary for Jekyll powered websites. Themes are created by me, Yuya Saito who is an web designer/frontend developer in Tokyo, Japan.<br>
_layouts is a theme gallary for Jekyll powered websites. Themes are created by me, Yuya Saito who is an web designer/frontend developer in Tokyo, Japan.<br>
Unless otherwise noted, themes here are all MIT licenced which means you can do whatever you want as long as you don't sue me. <br>
You can read more detail on license at <a href="https://github.com/studiomohawk/_layouts">my github repository</a><br>
You can read more detail on my github repository.<br>
And of course, this site is powerd by <a href="https://github.com/mojombo/jekyll">jekyll</a>.<br>
</p>
7 changes: 7 additions & 0 deletions _includes/footer.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<footer id="foot">
<div class="foot_inner">
<div class="hasGrid">
<div class="left alpha grid-6">{% include about.html %}</div>
<div class="right omega grid-6">{% include misc.html %}</div>
</div>
</footer><!-- id="foot" -->
6 changes: 3 additions & 3 deletions _includes/ga.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<!-- asynchronous google analytics: mathiasbynens.be/notes/async-analytics-snippet
change the UA-XXXXX-X to be your site's ID -->
<!-- You may want to stats with your blog if not you should erase this file and remove inculude link from
You don't need to edit this file, you can set your ID at _config.yml -->
<script>
var _gaq = [['_setAccount', 'UA-61203-14'], ['_trackPageview']];
var _gaq = [['_setAccount', '{{ site.ga }}'], ['_trackPageview']];
(function(d, t) {
var g = d.createElement(t),
s = d.getElementsByTagName(t)[0];
Expand Down
8 changes: 8 additions & 0 deletions _includes/header.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
<header id="head">
<div class="head_inner">
<ul>
<li class="logo"><a href="/">{{ site.sitename }}</a></li>
<li class="tagline">{{ site.tagline }}</li>
</ul>
</div>
</header><!-- id="head" -->
4 changes: 2 additions & 2 deletions _includes/misc.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<h4>if you like what i've done</h4>
<ul>
<li>you could give me an invite for <del><a href="http://forrst.com/">Forrst</a></del> <a href="http://forrst.com/people/studiomohawk">I've got it</a>. Thanks!</a></li>
<li>or you can follow me at <a href="http://twitter.com/#!/cssradar" rel="me">Twitter</a></li>
<li>Follow me at <a href="http://forrst.com/people/studiomohawk" rel="me">Forrest</a></li>
<li>Or <a href="http://twitter.com/#!/cssradar" rel="me">Twitter</a></li>
</ul>
<h4>contact</h4>
<ul>
Expand Down
2 changes: 2 additions & 0 deletions _includes/system_foot.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.5.0/jquery.js"></script>
{% include ga.html %}
25 changes: 25 additions & 0 deletions _includes/system_head.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
<!DOCTYPE html>
<!--[if lt IE 7 ]> <html lang="en" class="no-js ie6"> <![endif]-->
<!--[if IE 7 ]> <html lang="en" class="no-js ie7"> <![endif]-->
<!--[if IE 8 ]> <html lang="en" class="no-js ie8"> <![endif]-->
<!--[if (gte IE 9)|!(IE)]><!--> <html lang="en" class="no-js"> <!--<![endif]-->
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="google-site-verification" content="{{ page.sitemap }}">
<link href="{{ site.url }}atom.xml" rel="alternate" title="{{ site.sitename }} | {{ site.tagline }}" type="application/atom+xml">
<link rel="stylesheet" media="all" href="/stylesheet/master.css">
<link rel="stylesheet" media="all" href="/stylesheet/mediaqueries.css">
<script src="/script/modernizr.js"></script>
{% case page.layout %}
{% when 'home' %}
<title>{{ site.sitename }} | {{ site.tagline }}</title>
<meta name="description" content="{{ page.desctiption }}">
{% when 'post' %}
<title>{{ page.title }} | {{ site.sitename }} | {{ site.tagline }}</title>
<meta name="description" content="{{ content | strip_html | truncatewords: 25 }}">
{% else %}
<title>{{ page.title }} | {{ site.sitename }} | {{ site.tagline }}</title>
<meta name="description" content="{{ page.desctiption }}">
{% endcase %}
</head>
Loading

0 comments on commit be29e38

Please sign in to comment.