Skip to content

Instantly share code, notes, and snippets.

View LetItRock's full-sized avatar
👨‍💻
coding...

Paweł Tymczuk LetItRock

👨‍💻
coding...
View GitHub Profile
@LetItRock
LetItRock / hyper.js
Last active April 21, 2018 05:05
Hyper config
// Future versions of Hyper may add additional config options,
// which will not automatically be merged into this file.
// See https://hyper.is#cfg for all currently supported options.
module.exports = {
config: {
// choose either `'stable'` for receiving highly polished,
// or `'canary'` for less polished but more frequent updates
updateChannel: 'stable',
@LetItRock
LetItRock / HashMap.java
Created December 10, 2017 20:00 — forked from Surendev/HashMap.java
HashMap implementation
package com.chapters.training;
import java.util.ArrayList;
import java.util.HashSet;
import java.util.List;
import java.util.Set;
public class HashMap<K , V> {
@LetItRock
LetItRock / map.java
Created December 10, 2017 20:00 — forked from seadowg/map.java
HashMap built naively with TDD (and Tests)
// The following code is a series of test that were written in the order you'll read them. After
// each test was written it was run against the HashMap and the implementation was updated if it
// failed. The HashMap code is the final implementation that was built naively to pass each test.
// The Tests:
public class HashMapTest {
private HashMap map;
// Set up an empty map before each test
@LetItRock
LetItRock / alexa_responses.txt
Created October 20, 2017 13:09
Definition of Alexa responses for intents
JenkinsBuild start build
JenkinsBuild run build
JenkinsBuild build
JenkinsBuild make build
JenkinsProjectName project {no name project|project}
JenkinsJobs get projects
JenkinsJobs get jobs
JobStatus status of {no name project|project}
JobStatus tell me status of {no name project|project}
JobStatus what is the status of {no name project|project}
@LetItRock
LetItRock / alexa.json
Created October 20, 2017 13:08
Definition of Alexa intents
{
"intents": [
{
"intent": "JenkinsBuild"
},
{
"slots": [
{
"name": "project",
"type": "AMAZON.LITERAL"
@LetItRock
LetItRock / index.js
Created October 18, 2017 15:55
Alexa skill which gives ability to build jenkins job with blame mode
var http = require('http');
var https = require('https');
exports.handler = (event, context, callback) => {
try {
switch(event.request.intent.name) {
case 'JenkinsBuild': {
processJenkinsProjectsIntent(event, context, true);
break;
}
@LetItRock
LetItRock / index.js
Last active October 18, 2017 13:45
Alexa skill to be able to run Jenkins jobs
var http = require('http');
exports.handler = (event, context, callback) => {
try {
switch(event.request.intent.name) {
case 'JenkinsBuild': {
processJenkinsBuildIntent(event, context);
break;
}
case 'JenkinsProjectName': {
@LetItRock
LetItRock / what-forces-layout.md
Created July 24, 2017 16:54 — forked from paulirish/what-forces-layout.md
What forces layout/reflow. The comprehensive list.

What forces layout / reflow

All of the below properties or methods, when requested/called in JavaScript, will trigger the browser to synchronously calculate the style and layout*. This is also called reflow or layout thrashing, and is common performance bottleneck.

Element

Box metrics
  • elem.offsetLeft, elem.offsetTop, elem.offsetWidth, elem.offsetHeight, elem.offsetParent
  • elem.clientLeft, elem.clientTop, elem.clientWidth, elem.clientHeight
  • elem.getClientRects(), elem.getBoundingClientRect()
@LetItRock
LetItRock / readme.md
Created May 24, 2017 18:14 — forked from rheajt/readme.md
sass setup for create-react-app cli tool

Create-React-App with Sass configuration

Here are instructions for add Sass support to an app built with create-react-app. Hopefully this will be redundant when Sass support is built into the tool! Visit their form and let them know you need Sass support.

Install the create-react-app tool from npm. This will be installed globally. We also need to install the loaders needed for webpack, and we will save those as development dependencies.

npm install -g create-react-app

create-react-app your-app-name
cd your-app-name