Skip to content

Commit

Permalink
Uploading site Sat 27 Apr 2019 14:05:28 BST
Browse files Browse the repository at this point in the history
  • Loading branch information
jordibares committed Apr 27, 2019
1 parent 46f23c7 commit 45961a3
Show file tree
Hide file tree
Showing 12 changed files with 224 additions and 117 deletions.
3 changes: 3 additions & 0 deletions _upload.sh
Expand Up @@ -2,6 +2,9 @@

echo -e "\033[0;32mUploading updates to GitHub...\033[0m"

# Remove silly DS_Store
find . -name ".DS_Store" -type f -depth -exec rm {} \;

# Add changes to git.
git add .

Expand Down
2 changes: 1 addition & 1 deletion content/docs/collaborating/authoring/_index.md
@@ -1,5 +1,5 @@
---
title: "Authoring"
title: "Authoring Workflow"
weight: 1
---

Expand Down
114 changes: 0 additions & 114 deletions content/docs/collaborating/authoring/config-system/index.md

This file was deleted.

86 changes: 86 additions & 0 deletions content/docs/collaborating/authoring/configuration/index.md
@@ -0,0 +1,86 @@
---
title: "Configuration"
weight: 10

categories: ["Collaborating"]
tags: ["Authoring", "Git"]

writer: "Jordi Bares"
---

# Configuration

{{< preamble >}}
The first step is to install and configure you computer with the necessary tools that you will need to create content.
{{< /preamble >}}

In order to author you need four things in your computer;

Brew
: This is a software package manager to install and manage tools.

Hugo
: This is the static web generator that builds houdini guides.

Git
: The version control system used to manage the book.

Git-LFS
: The plugin in charge of handling large media.


{{< alert type="danger" title="CRITICAL" >}}
If you are not familiar with Git, it is better you do this before requesting to colaborate as it is fundamental for every single interaction with the book source.
Visit [Git Documenation](https://git-scm.com/book/en/v2) first and get familiar with it please.
{{< /alert >}}



## Install Brew on Mac OSX

We first need to install Brew which is a package manager and will allow you to configure your mac in a comfortable way, it is really cool actually.

``` bash
> /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
```

For more information have a look at [Brew](https://brew.sh)

## Install Hugo on Mac OSX

The Houdini Guides uses Hugo which is a static web page generator, a kind of clever conversion from markdown to html which renders websites that are very light and fast becuase they don't use databases, only front-end stuff.

Please read this as well [Installing Hugo](https://gohugo.io/getting-started/installing/) information for all platforms.

For Mac OSX, use this...

``` bash
> brew install hugo
```

Now you will be able to run hugo and test your posts, for information have a look at [Hugo](https://gohugo.io)


## Install Git on Mac OSX

If you have installed [Xcode](https://developer.apple.com/xcode/), you surely have Git already installed too, but in case you haven't yet, [Download](https://git-scm.com/downloads) Git and install it, here you have some important [Git Videos](https://git-scm.com/doc) to get your head around it.

For a quick starter, this [Tutorial](https://medium.freecodecamp.org/what-is-git-and-how-to-use-it-c341b049ae61) is an excellent begginer explantion of what Git is.

Now that you have installed successfully brew, hugo and git we can proceed to connecting with the book repository and start collaborating.

## Install Git-LFS on Mac OSX

As you should know by now, Git is superb with non-binary data, but images and caches and alembic files are truly a major issue, for this reason the community has developed a plugin that works on top of Git in a transparent manner that has become almost the standard as GitHub and Altassian are behind it.

Welcome to [Git-LFS](https://git-lfs.github.com) which stands for Large File Storage and in a friendly way deals with binary objects.

Let's install Git LFS and now you will have everything in your system to start building repositories with clever binary data management.

``` bash
> brew install git-lfs
```

Simples!


124 changes: 124 additions & 0 deletions content/docs/collaborating/authoring/workflow/index.md
@@ -0,0 +1,124 @@
---
title: "Authoring Workflow"
weight: 15

categories: ["Collaborating"]
tags: ["Authoring", "Git"]

writer: "Jordi Bares"
---

# Authoring workflow

{{< preamble >}}
Collaborating is a resposibility, therefore please make sure you get acquainted with Git and GitHub.
{{< /preamble >}}


These are the normal steps involved;

Create a GitHub account
: You need to create your own github account as this is where you will be saving your version of the book.

Fork the repository
: Basically you will be copying the book to your repository by "forking it".

Download your fork locally
: Now you can download the your own copy of book, "your fork", to your computer using Git, which by now you should be very familiar with.

Do your changes
: Create new pages alter others and explore "what if" scenarios in the safety that this is your own copy of the book.

Push your changes
: Once you are happy, you will upload or "push" those changes to your own github fork.

Create a pull request
: Now is time to notify me that you want me to merge things, this is called a "pull request" and I will go over every single change you want me to merge, of course, some may need extra work and this will go back and forth for a bit until I am satisfied and approve it.

Merge
: Your branch will be merged with mine and will go live for everyone to see.


## Create a GitHub account

You need to create a [GitHub](https://github.com) acocunt if you don't have one already before proceeding, this is how.

If you don't know GitHub I will strongly suggest you check the various [GitHub Official Training Guides](https://www.youtube.com/githubguides) or other [YouTube tutorials](https://www.youtube.com/watch?v=SWYqp7iY_Tc) and [online git books](https://guides.github.com/introduction/flow/) and [onlinne gihub books](https://launchschool.com/books/git/read/introduction) which surely will help you, not only to collaborate but on your own projects.

## How to fork a repository

The best thing to do is to go to the (GitHub help pages](https://help.github.com/en/articles/fork-a-repo) on how to fork a repository and the cloning proces.

``` bash
> git clone https://github.com/<YOUR-GITHUB-USERNAME>/houdini-guides
```

Now you will have a clone of your own version of the houdini-guides in your local drive, you can do whatever you want here without fear or breaking anything at all.

## Create a new post

Create new posts using the correct structure is not hard, just have a look at the book structure that has been downloaded and you will see quite clearly how things are setup.

For example, to create a chapter on the animation part-2

``` bash
> hugo new post book/part-2/animation/keyframing/index.md
```

Will create a chapter under the animation block and the indes.md is the document you need to add your text, images and what not.

Please check the markdown guid and the style guide to find more about it.

### Grammar

I am not a native speaker so I need all help I can get, for this reason I highly recommend using [Grammarly](https://www.grammarly.com) to correct or even write the articles.

### Dealing with images

The strategy is to keep your original images including photoshop files and the likes under the article folder like this..

..and produce lightweight jpg versions that we can use for the web pages, this are the ones you should link to.

{{< alert type="info" title="JPEG Compression" >}}
Make sure you use MozJPEG codec to compress these images to the maximum. I normally use [Image Optim](https://imageoptim.com/mac) during my authoring process to make sure I have really fast page loading.
{{< /alert >}}

### Dealing with diagrams

At the moment this has not been put in place but very soon I will be installing a markdown style diagraming system so we can produce text based diagramas that render on the fly rather than dealing with heavy images, staty tuned.

## Publishing your changes

Once you are done with the content, double checked your grammar, typos and what not (I recommend using Grammarly for this), you can publish it to your GitHub repository like this

``` bash
> git add --all
> git commit -m "New keyframing chapter under animation"
> git push
```

## Doing a Pull Request

Now go to the original [GitHub Houdinig Guides repository](https://github.com/jordibares/houdini-guides-website) and click on [Pull request](https://github.com/jordibares/houdini-guides-website/pulls);

![Pull Request Menu][2]

## Merging with main branch

Once the pull request is approved I will proceed to merge it and will become live immediatly.

{{< poster >}}
Image of the pull merge process
{{< /poster >}}


## Deleting your fork

Once I have merged your brand you may want to delete your fork and start the process again with a new fork. Remember that there may be lots of people collaborating and your branch will become obsolete very rapidly.

{{< poster >}}
Image of the branch history / graph
{{< /poster >}}

[1]: config-git__1_menu.jpg
[2]: config-git__2_pull-request.jpg
8 changes: 8 additions & 0 deletions content/posts/2019-04-27__revamp-formatting.md
@@ -0,0 +1,8 @@
---
title: "Revamp Formatting"
date: 2019-04-27T14:03:33+01:00
---

A final review of the look and CSS configuration, new widgets like accordions and code blocks are now available.

Furthermore separate the authoring workflow and add necessary information to GitLFS which I have converted the site to.
2 changes: 1 addition & 1 deletion layouts/shortcodes/alert.html
Expand Up @@ -151,5 +151,5 @@
<div class="hg-alert--info">
{{ end }}
<title>{{.Get "title"}}</title>
<p>{{ .Inner }}</p>
<p>{{ .Inner | markdownify }}</p>
</div>
2 changes: 1 addition & 1 deletion layouts/shortcodes/badge.html
Expand Up @@ -26,5 +26,5 @@
</style>

<div class="hg-badge">
<p>{{ .Inner }}</p>
<p>{{ .Inner | markdownify }}</p>
</div>

0 comments on commit 45961a3

Please sign in to comment.