Skip to content

Instantly share code, notes, and snippets.

Hugo transition notes 16 Apr 2018

BEP - Bjørn's effort

  • branch: hugo-migration

  • example site at 'https://k8sio-hugo-migration.netlify.com/'

  • glossary moved into a "page bundle" structure in hugo

    • when you start to translate, it makes a sort of overlay so that what's not translated reflects whatever the base content/language was provided
@heckj
heckj / hugo_transition_notes_17Apr 2018.md
Last active April 17, 2018 16:08
Hugo transition notes 17 Apr 2018

Hugo transition notes 17 Apr 2018

  • https://k8sio-hugo-migration.netlify.com/
  • significant progress from yesterday
  • updating logic behind conversation of the Table of Contents(ToC)
    • will probably need some manual cleanup, but more effective to navigate today
    • "example tutorial template" showing up - set a flagon front-matter to hide it from the ToC
    • all the configuration needed is basically "adding a content file" into the directory
  • worked through conversion of the templating for concepts and tasks
  • yesterday highlights the "callout" syntax
@heckj
heckj / gist:8912c963c66ab12b6bb21dd7947399e6
Created April 30, 2018 16:38
Xbee 2.3.2 pip log (failure)
/home/vagrant/src/Collector/.venv/bin/pip run on Mon Apr 30 16:36:53 2018
Downloading/unpacking xbee
Getting page https://pypi.python.org/simple/xbee/
URLs to search for versions for xbee:
* https://pypi.python.org/simple/xbee/
Analyzing links from page https://pypi.org/simple/xbee/
Found link https://files.pythonhosted.org/packages/ad/10/a5b557556abe4a85f8ecfc492bbc701e5e18ebb1756e618757f059fb1938/XBee-1.5.0.tar.gz#sha256=034e55dacedf2cbf83779da8f8787471456e1d70fd1270d9c72109a6a69ee489 (from https://pypi.org/simple/xbee/), version: 1.5.0
Found link https://files.pythonhosted.org/packages/f7/7f/1bf173e0bd86b145bd1e5e3de890720137e0d3acc7e72a28a335235270c6/XBee-1.7.0.tar.gz#sha256=6247e37a85b745d87824d6fc3e1d7fb5956f67963b0f5818da353558fb4fb0bd (from https://pypi.org/simple/xbee/), version: 1.7.0
Found link https://files.pythonhosted.org/packages/7f/9b/f37a55241c12a8b93093649eebb46ff6acd9b1e755a2ade956e8e0e1bd6f/XBee-1.7.1.zip#sha256=ccacedf01c25a18670f4fcd0c3974aed673194687cad5e22a8cf16a308
Making script /home/vagrant/src/Ruler/.rt-Linux-x86_64/bin/pyi-bindepend relative
27 INFO: PyInstaller: 3.3.1
27 INFO: Python: 2.7.6
28 INFO: Platform: Linux-3.13.0-142-generic-x86_64-with-Ubuntu-14.04-trusty
28 INFO: wrote /home/vagrant/src/Ruler/ruler_server.spec
32 INFO: UPX is not available.
33 INFO: Removing temporary files and cleaning cache in /home/vagrant/.cache/pyinstaller
34 INFO: Extending PYTHONPATH with paths
['/home/vagrant/src/Ruler/src', '/home/vagrant/src/Ruler']
35 INFO: checking Analysis
### Keybase proof
I hereby claim:
* I am heckj on github.
* I am heckj (https://keybase.io/heckj) on keybase.
* I have a public key ASB6Bo2r9fnLSfcqGzYfIoiIiS9ndQZ1LAzJQno0YwePQgo
To claim this, I am signing this object:
extension UIImageView {
var contentClippingRect: CGRect {
guard let image = image else { return bounds }
guard contentMode == .scaleAspectFit else { return bounds }
guard image.size.width > 0, image.size.height > 0 else { return bounds }
let scale: CGFloat
let scaleByWidth = bounds.width / image.size.width
let scalebyHeight = bounds.height / image.size.height
<?xml version="1.0" encoding="UTF-8"?>
<!-- OPML generated by NetNewsWire -->
<opml version="1.1">
<head>
<title>IOSDev.opml</title>
</head>
<body>
<outline text="Official Swift Blog" title="Official Swift Blog" description="" type="rss" version="RSS" htmlUrl="https://developer.apple.com/swift/blog/" xmlUrl="https://developer.apple.com/swift/blog/news.rss"/>
<outline text="Xcoders" title="Xcoders" description="" type="rss" version="RSS" htmlUrl="https://xcoders.org/" xmlUrl="https://xcoders.org/feed.json"/>
<outline text="The Shape of Everything" title="The Shape of Everything" description="" type="rss" version="RSS" htmlUrl="http://shapeof.com/" xmlUrl="http://shapeof.com/feed.json"/>
@heckj
heckj / attributes.rb
Created April 20, 2019 21:33 — forked from lizthegrey/attributes.rb
Hardening SSH with 2fa
default['sshd']['sshd_config']['AuthenticationMethods'] = 'publickey,keyboard-interactive:pam'
default['sshd']['sshd_config']['ChallengeResponseAuthentication'] = 'yes'
default['sshd']['sshd_config']['PasswordAuthentication'] = 'no'
@heckj
heckj / Cylinder.swift
Created April 20, 2019 22:24
A Reusable SCNNode SubClass With An SCNCylinder Geometry
//
// Cylinder.swift
//
//
// Created by Josh Robbins on 24/02/2018.
// Copyright © 2018 BlackMirror. All rights reserved.
//
import Foundation
import SceneKit
@heckj
heckj / MetalWireFrameShader.metal
Created April 20, 2019 22:28
Wireframe Shader For An SCNBox Geometry
/*
Copyright © 2018 Apple Inc.
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:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,