Skip to content
Permalink
Browse files

adapt to npf.io themes and add social stuffs

  • Loading branch information
htr3n committed Jan 21, 2018
1 parent 5814b3e commit 331ef48d5c922a878ee1b143fb809e9b1434c9bb
@@ -2,6 +2,4 @@

## Version 1.0

- Due to the switch to the base template feature the minimum required version of Hugo changed to v0.21
- Support for Google Analytics have been added
- Hugo's internal Disqus template replaced the custom one of this theme. The Disqus shortname now has to be defined outsite the `[params]` blog
- Fork from [Hyde](https://github.com/spf13/hyde) and adapt to [Nate Finch's blog](https://npf.io)'s colors and fonts.
@@ -1,6 +1,6 @@
# Released under MIT License

Copyright (c) 2013 Mark Otto.
Copyright (c) 2018 Huy Tran.

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 to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

153 README.md
@@ -1,166 +1,61 @@
# Hyde
# hyde-hyde

Hyde is a brazen two-column [hugo](https://gohugo.io) theme based on the [Jekyll](http://jekyllrb.com) theme of the same name.
It pairs a prominent sidebar with uncomplicated content.
__`hyde-hyde`__ is a [Hugo](https://gohugo.io)'s theme derived from @spf13's [Hyde](https://github.com/spf13/hyde.git) which is in turn ported from @mdo Jekyll's [Hyde](https://github.com/poole/hyde).

![Hyde screenshot](https://f.cloud.github.com/assets/98681/1831228/42af6c6a-7384-11e3-98fb-e0b923ee0468.png)


## Contents

- [Installation](#installation)
- [Options](#options)
- [Sidebar menu](#sidebar-menu)
- [Sticky sidebar content](#sticky-sidebar-content)
- [Themes](#themes)
- [Reverse layout](#reverse-layout)
- [Disqus](#disqus)
- [Google Analytics](#google-analytics)
- [Author](#author)
- [Ported by](#ported-by)
- [License](#license)


## Installation

To install Hyde as your default theme, first install this repository in the `themes/` directory:
`hyde-hyde` can be easily installed as other themes:

$ cd themes/
$ git clone https://github.com/spf13/hyde.git

Second, specify `hyde` as your default theme in the `config.toml` file. Just add the line

theme = "hyde"

at the top of the file.


## Options

Hyde includes some customizable options, typically applied via classes on the `<body>` element.


### Sidebar menu

Create a list of nav links in the sidebar by assigning "menu=main" in the front matter.


### Sticky sidebar content

By default Hyde ships with a sidebar that affixes it's content to the bottom of the sidebar. You can optionally disabled this by removing the `.sidebar-sticky` class from the sidebar's `.container`. Sidebar content will then normally flow from top to bottom.

```html
<!-- Default sidebar -->
<div class="sidebar">
<div class="container sidebar-sticky">
...
</div>
</div>

<!-- Modified sidebar -->
<div class="sidebar">
<div class="container">
...
</div>
</div>
```sh
$ cd HUGO_SITE
# then clone hyde-hyde
$ git clone https://github.com/htr3n/hyde-hyde.git themes/hyde-hyde
# or add hyde-hyde as a submodule
$ git submodule add https://github.com/htr3n/hyde-hyde.git themes/hyde-hyde
```

Then indicate `hyde-hyde` as the main theme

### Themes

Hyde ships with eight optional themes based on the [base16 color scheme](https://github.com/chriskempson/base16). Apply a theme to change the color scheme (mostly applies to sidebar and links).

![Hyde in red](https://f.cloud.github.com/assets/98681/1831229/42b0b354-7384-11e3-8462-31b8df193fe5.png)

There are eight themes available at this time.
* `config.toml`

![Hyde theme classes](https://f.cloud.github.com/assets/98681/1817044/e5b0ec06-6f68-11e3-83d7-acd1942797a1.png)
theme = "hyde-hyde"
* `config.yaml`

To use a theme, add the `themeColor` variable under `params`, like so:

**TOML**
```toml
theme = "hyde"
[params]
themeColor = "theme-base-09"
```

**YAML**
```yaml
theme: "hyde"
params:
themeColor: "theme-base-09"
theme : "hyde-hyde"
```

To create your own theme, look to the Themes section of [included CSS file](https://github.com/poole/hyde/blob/master/public/css/hyde.css). Copy any existing theme (they're only a few lines of CSS), rename it, and change the provided colors.

### Reverse layout

![Hyde with reverse layout](https://f.cloud.github.com/assets/98681/1831230/42b0d3ac-7384-11e3-8d54-2065afd03f9e.png)

To reverse page orientation, add the `layoutReverse` variable under `params`, like so:

**TOML**
```toml
theme = "hyde"
[params]
layoutReverse = true
```

**YAML**
```yaml
theme: "hyde"
params:
layoutReverse: true
```

### Disqus

You can optionally enable a comment system powered by Disqus for the posts. Simply add the variable `disqusShortname` to your config file.

**TOML**
```toml
disqusShortname = "spf13"
```

**YAML**
```yaml
disqusShortname : spf13
```

> **Note:** Previous version 1.0 the Disqus shortname had to be defined inside the `[params]` block.

## Google Analytics
## Options

Google Analytics can be enabled by assigning your tracking code to the `googleAnalytics` variable in the config file:
* `hyde-hyde` essentially inherits all options from [Hyde](https://github.com/spf13/hyde).

**TOML**
```toml
googleAnalytics = "Your tracking code"
```
## Author(s)
### Original Developed by Mark Otto

**YAML**
```yaml
googleAnalytics: Your tracking code
```

## Author
**Mark Otto**
- <https://github.com/mdo>
- <https://twitter.com/mdo>

## Ported By
**Steve Francia**
### Hugo's Hyde Ported by Steve Francia
- <https://github.com/spf13>
- <https://twitter.com/spf13>

### Color Theme Inspired By

* [Nate Finch's blog](https://npf.io)

## License

Open sourced under the [MIT license](LICENSE.md).

<3

@@ -1,6 +1,7 @@
+++
Description = ""
Tags = ["Development", "golang"]
Categories = ["Development", "GoLang"]
menu = "main"
+++
---
title: "{{ replace .TranslationBaseName "-" " " | title }}"
date: {{ .Date }}
tags : ["Dev", "Go"]
categories : ["Dev", "Go"]
draft: true
---
@@ -0,0 +1,3 @@
/public
/themes
.DS_Store
@@ -0,0 +1,49 @@
## Basic Configuration
baseurl = "http://localhost:1313/"
languageCode = "en"

theme = "hyde-hyde"
paginate = 7

## Hugo Built-in Features
disqusShortname = ""
googleAnalytics = ""
enableRobotsTXT = true

## Site Settings
[params]
author = "Author"
title = "Title"
# description = "..."
authorimage = "/img/hugo.png"
dateformat = "Jan 1, 2006"

## Social Accounts
[params.social]
github = "<username>"
instagram = "<username>"
xing = "<username>"
linkedin = "<username>"
twitter = "<username>"
facebook = "<username>"
stackoverflow = "<username>"
email = "your-email@example.com"

## Extras
[params.extra]
copyright = "© 2018. [Some Rights Reserved](http://creativecommons.org/licenses/by/3.0/)."
poweredby = true
# highlightjs = true
# highlightjsstyle = "github"

## Main Menu
[[menu.main]]
name = "Posts"
weight = 100
identifier = "posts"
url = "/posts/"
[[menu.main]]
name = "About"
identifier = "about"
weight = 200
url = "/about/"
@@ -0,0 +1,17 @@
+++
title = "About Hugo"
date = "2014-04-09"
+++

Hugo is a static site engine written in Go.


It makes use of a variety of open source projects including:

* [Cobra](https://github.com/spf13/cobra)
* [Viper](https://github.com/spf13/viper)
* [J Walter Weatherman](https://github.com/spf13/jWalterWeatherman)
* [Cast](https://github.com/spf13/cast)

Learn more and contribute on [GitHub](https://github.com/gohugoio).

0 comments on commit 331ef48

Please sign in to comment.
You can’t perform that action at this time.