Skip to content

Instantly share code, notes, and snippets.


Björn Söderqvist cybear

  • Greenfield AB
  • Malmo, Sweden
View GitHub Profile
cybear / Why you should learn gh
Last active Apr 30, 2020
Frontenders: This is why you should learn Github Actions
View Why you should learn gh

Intro / pitch

  • My code broke the live site. Why didn't it do what I intended for it to do? How did it get all the way to production?

You're probably a frontend developer like me.

In this article I will try to convince you that you should learn to automate some actions for your repo.

Feedback cycles


Hire me - Raise your frontend to a whole new level

I'm looking for a new gig (contractor / consultant).

Location: Malmö or Lund

Start: August

Some examples of what I can do:

cybear / placeholder.svg.js
Created May 6, 2019
SVG image placeholder with correct dimensions and background color
View placeholder.svg.js
const prefix = "data:image/svg+xml,";
export default props =>
prefix +
viewBox='0 0 ${props.width} ${props.height}'>
while read path
mkdir -p "$path"
svtplay-dl -MAts -o "$path/" "$path" &
sleep 15
done < $1
cybear /
Last active Oct 9, 2017
SVT Play download all episodes of all shows
while read path
mkdir -p "$path"
svtplay-dl -MAts -o "$path/" "$path" &
done < $1

Keybase proof

I hereby claim:

  • I am cybear on github.
  • I am tap5 ( on keybase.
  • I have a public key whose fingerprint is 3D08 BBDC CF72 E40B A709 BDCE C2B7 BD65 1385 D7A3

To claim this, I am signing this object:

cybear /
Created Mar 10, 2015
Writing tips for error messages

Writing tips for error messages

  • Describe the cause of the error, if possible.
  • Avoid blaming the user. "You typed a URL that doesn't exist" => "We can't find any page at this URL"
  • Avoid impersonal writing. "Could not upload selected files" => "We could not upload the files that you selected"
  • Suggest a next action for the user if it is plausible.
cybear / colors.html
Created Oct 9, 2014
one-color.js and js arrays in chrome dev console
View colors.html
<title>Color development console</title>
<script src=""></script>
<script type="text/javascript">
function logColor(oneColor) {
var c = oneColor.hex();
console.log( '%c'+c, 'background:' + c);
return oneColor;
cybear /
Created Aug 14, 2014
iOS Simulator cache buster
killall "iPhone Simulator"
folder="/Users/cybear/Library/Application\ Support/iPhone\ Simulator/7.1"
rm -rf $folder/Media/PhotoData/Caches
rm -rf $folder/Media/PhotoData/Thumbnails
rm -rf $folder/tmp
rm -rf $folder/Library/Cookies
rm -rf $folder/Library/TCC
rm -rf $folder/Library/Passes
rm -rf $folder/Library/Calendar
cybear / gist:bdf357186de14d44cd97
Created May 14, 2014
Demodag hilite demoing people
View gist:bdf357186de14d44cd97 (document.querySelectorAll('tr'),0)
var c = el.querySelector('.class_7');
return c&&c.innerText;
return el;
You can’t perform that action at this time.