Encode your private RSA key
$ cat my_private_key | base64 -w0
# -w0 to avoid newlines
Add the base64 string to your project variables. Use it in your .gitlab-ci.yml
| import { useState, useEffect } from 'react'; | |
| // Usage | |
| function App() { | |
| // Call our hook for each key that we'd like to monitor | |
| const happyPress = useKeyPress('h'); | |
| const sadPress = useKeyPress('s'); | |
| const robotPress = useKeyPress('r'); | |
| const foxPress = useKeyPress('f'); |
Encode your private RSA key
$ cat my_private_key | base64 -w0
# -w0 to avoid newlines
Add the base64 string to your project variables. Use it in your .gitlab-ci.yml
| import { resolve } from 'path' | |
| import { GatsbyCreatePages } from './types' | |
| const createPages: GatsbyCreatePages = async ({ | |
| graphql, | |
| boundActionCreators, | |
| }) => { | |
| const { createPage } = boundActionCreators | |
| const allMarkdown = await graphql(` |
The only way I've succeeded so far is to employ SSH.
Assuming you are new to this like me, first I'd like to share with you that your Mac has a SSH config file in a .ssh directory. The config file is where you draw relations of your SSH keys to each GitHub (or Bitbucket) account, and all your SSH keys generated are saved into .ssh directory by default. You can navigate to it by running cd ~/.ssh within your terminal, open the config file with any editor, and it should look something like this:
Host * AddKeysToAgent yes
> UseKeyChain yes
| // Reference: http://www.blackdogfoundry.com/blog/moving-repository-from-bitbucket-to-github/ | |
| // See also: http://www.paulund.co.uk/change-url-of-git-repository | |
| $ cd $HOME/Code/repo-directory | |
| $ git remote rename origin bitbucket | |
| $ git remote add origin https://github.com/mandiwise/awesome-new-repo.git | |
| $ git push origin master | |
| $ git remote rm bitbucket |
| function getGreetingTime (m) { | |
| var g = null; //return g | |
| if(!m || !m.isValid()) { return; } //if we can't find a valid or filled moment, we return. | |
| var split_afternoon = 12 //24hr time to split the afternoon | |
| var split_evening = 17 //24hr time to split the evening | |
| var currentHour = parseFloat(m.format("HH")); | |
| if(currentHour >= split_afternoon && currentHour <= split_evening) { |