Compare commits

..

No commits in common. "cb275ad95d14af05958ecaa62bfeb69ac2b13a1c" and "2396106339d009fa230c6bc98ddd86605623d333" have entirely different histories.

5 changed files with 21 additions and 64 deletions

2
.gitignore vendored
View File

@ -1,3 +1,3 @@
export/
build/
.venv/
*.conf

View File

@ -1,3 +1,3 @@
clean:
rm --recursive --force export
rm --recursive --force build
rm --force nginx.conf

View File

@ -122,12 +122,6 @@ class ConfigSerializer(msh.Schema):
f"Post slugs used multiple times: {set([item for item in slugs if slugs.count(item) > 1])}"
)
@msh.post_load
def _remove_future(self, data: Dict[str, Any], *args, **kwargs) -> PostContainer:
posts = [item for item in data["posts"] if item.date >= datetime.date.today()]
data["posts"] = posts
return data
def get_args() -> argparse.Namespace:
parser = argparse.ArgumentParser()
@ -137,6 +131,7 @@ def get_args() -> argparse.Namespace:
parser.add_argument(
"-c", "--check", action="store_true", help="Check the config without building"
)
parser.add_argument("-p", "--publish", action="store_true", help="Publish the site")
return parser.parse_args()
@ -144,7 +139,7 @@ def main():
args = get_args()
cwd = Path.cwd().resolve()
output = cwd / "export"
output = cwd / "build"
explore = output / "explore"
with Path(args.config).resolve().open() as infile:

View File

@ -7,33 +7,6 @@ static:
- index.html
- robots.txt
posts:
- title: Talcott's "Castle on the Mountain" does not dissapoint
slug: heubline-tower
location:
title: Simsbury, CT
link: https://maps.google.com
date: "2020-01-01"
banner: https://cdn.enp.one/img/backgrounds/cl-photo-denver.jpg
media: []
- title: The three hundred year old fort with delusions of grandeur
slug: fort-revere
location:
title: Hull, MA
link: https://maps.google.com
date: "2020-01-01"
banner: https://cdn.enp.one/img/backgrounds/cl-photo-denver.jpg
media: []
- title: Supervillian lair or air traffic control station?
slug: jss-north-truro
location:
title: North Truro, MA
link: https://maps.google.com
date: "2020-01-01"
banner: https://cdn.enp.one/img/backgrounds/cl-photo-denver.jpg
media: []
- title: A 1:1 recreation of the set for Star Trek the Original Series
slug: star-trek-set-tours
location:
@ -44,22 +17,16 @@ posts:
links:
- title: Star Trek Set Tours
link: https://www.startrektour.com/
media: []
- title: The most successful forest conservation project in the USA
slug: mount-greylock
location:
title: North Adams, MA
link: https://maps.google.com
date: "2020-01-01"
banner: https://cdn.enp.one/img/backgrounds/cl-photo-denver.jpg
media: []
- title: Ghosts of parties past are the last inhabitants of this magnificent forest castle
slug: castle-of-madame-sherri
location:
title: Chesterfield, NH
link: https://maps.google.com
date: "2020-01-01"
banner: https://cdn.enp.one/img/backgrounds/cl-photo-denver.jpg
media: []
media:
- title: Foo Bar Baz
content: Fizz buzz, lorem ipsum dolher, siamet
source: https://cdn.enp.one/img/backgrounds/cl-network.jpg
- title: Foo Bar Baz
content: Fizz buzz, lorem ipsum dolher, siamet
source: https://cdn.enp.one/img/backgrounds/cl-network.jpg
- title: Foo Bar Baz
content: Fizz buzz, lorem ipsum dolher, siamet
source: https://cdn.enp.one/img/backgrounds/cl-network.jpg
- title: Foo Bar Baz
content: Fizz buzz, lorem ipsum dolher, siamet
source: https://cdn.enp.one/img/backgrounds/cl-network.jpg

View File

@ -1,8 +1,3 @@
error_page 404 error/404.html;
location = error/404.html {
internal;
}
location = robots.txt {
allow all;
log_not_found off;