Exclude files for deployment
Remove deprecated Hakyll files
This commit is contained in:
parent
4190f85a2b
commit
5d38e08010
18
Makefile
18
Makefile
|
@ -1,12 +1,5 @@
|
|||
TARGET=site
|
||||
|
||||
all: site.hs
|
||||
ghc $< -o ${TARGET}
|
||||
|
||||
build: all
|
||||
./${TARGET} build
|
||||
|
||||
tup:
|
||||
rm -rf preview
|
||||
tup build
|
||||
|
||||
preview: tup
|
||||
|
@ -14,9 +7,14 @@ preview: tup
|
|||
cp -r build preview
|
||||
rm -f preview/tup.config
|
||||
|
||||
clean:
|
||||
git nuke
|
||||
|
||||
graph:
|
||||
tup graph . | dot -Tpng > graph.png
|
||||
|
||||
deploy: tup
|
||||
rsync --checksum -ave 'ssh -p 4242' \
|
||||
deploy: clean tup
|
||||
rsync --checksum --copy-links -ave 'ssh -p 4242' \
|
||||
--exclude=templates \
|
||||
--exclude=tup* \
|
||||
build/* fab@ffreling.com:public_html/ffreling.com/public/
|
||||
|
|
46
site.hs
46
site.hs
|
@ -1,46 +0,0 @@
|
|||
-----------------------------------------------------------
|
||||
{-# LANGUAGE Arrows #-}
|
||||
{-# LANGUAGE OverloadedStrings #-}
|
||||
module Main where
|
||||
|
||||
-----------------------------------------------------------
|
||||
import Control.Applicative ((<$>))
|
||||
import Data.Monoid (mappend, mconcat)
|
||||
import Prelude hiding (id)
|
||||
import System.FilePath (replaceExtension, takeDirectory)
|
||||
import qualified Text.Pandoc as Pandoc
|
||||
|
||||
|
||||
-----------------------------------------------------------
|
||||
import Hakyll
|
||||
|
||||
|
||||
-----------------------------------------------------------
|
||||
-- | Entry point
|
||||
main :: IO ()
|
||||
main = hakyllWith config $ do
|
||||
|
||||
match ("images/*" .||. "favicon.png" .||. "files/*" .||. "font/**"
|
||||
.||. "projects/*/*.html") $ do
|
||||
route idRoute
|
||||
compile copyFileCompiler
|
||||
|
||||
match "css/*" $ do
|
||||
route idRoute
|
||||
compile compressCssCompiler
|
||||
|
||||
match "templates/*" $ compile $ templateCompiler
|
||||
|
||||
match ("*.md" .||. "projects/*/*.md") $ do
|
||||
route $ setExtension "html"
|
||||
compile $ pandocCompiler
|
||||
>>= loadAndApplyTemplate "templates/default.html" defaultContext
|
||||
>>= relativizeUrls
|
||||
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
config :: Configuration
|
||||
config = defaultConfiguration
|
||||
{ deployCommand = "rsync --checksum -ave 'ssh -p 4242' \
|
||||
\_site/* fab@ffreling.com:public_html/ffreling.com/public/"
|
||||
}
|
|
@ -1,30 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
|
||||
<title>Fabien Freling's website</title>
|
||||
<link rel="icon" type="image/png" href="http://www.ffreling.com/favicon.png">
|
||||
<link href='http://fonts.googleapis.com/css?family=Anaheim' rel='stylesheet' type='text/css'>
|
||||
<link href='http://fonts.googleapis.com/css?family=Average+Sans' rel='stylesheet' type='text/css'>
|
||||
<link rel="stylesheet" type="text/css" href="/css/default.css" />
|
||||
<link rel="stylesheet" type="text/css" href="/css/syntax.css" />
|
||||
<link rel="stylesheet" href="/font/font-awesome-4.3.0/css/font-awesome.min.css">
|
||||
</head>
|
||||
<body>
|
||||
<div id="banner"></div>
|
||||
|
||||
<div id="navigation">
|
||||
<a href="/index.html">Home</a>
|
||||
<a href="/projects.html">Projects</a>
|
||||
<a href="/about.html">About</a>
|
||||
</div>
|
||||
|
||||
<h1>$title$</h1>
|
||||
|
||||
$body$
|
||||
|
||||
<div id="footer">
|
||||
Copyright © Fabien Freling 2007-2016
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
Loading…
Reference in a new issue