Skip to content

Instantly share code, notes, and snippets.

Avatar
🧶
Knitting the next thing

Rui rpbaltazar

🧶
Knitting the next thing
View GitHub Profile
@rpbaltazar
rpbaltazar / server.py
Created Oct 7, 2020
python server.py
View server.py
from http.server import HTTPServer, BaseHTTPRequestHandler
from io import BytesIO
class SimpleHTTPRequestHandler(BaseHTTPRequestHandler):
def do_GET(self):
self.send_response(200)
self.end_headers()
View git flows
ousama--ooooooooo
|
develop----------------------------->ooooooooo
|
nuno________________________________>xxxx
gco develop
g pull
View rubocop-loop.sh
# /bin/bash
x=0
while [ $x -eq 0 ]
do
rubocop -C false -a -F | grep 'offense detected' &> /dev/null
x=$?
echo "Finished $x"
done
echo $x
@rpbaltazar
rpbaltazar / Makefile
Last active May 24, 2020
githooks examples
View Makefile
init:
find .git/hooks -type l -exec rm {} \;
find .githooks -type f -exec ln -sf ../../{} .git/hooks/ \;
View .github-config-rubocop_linter_action.yml
check_name: 'Rubocop Results'
versions:
- rubocop: '0.75.1'
- rubocop-rails: '2.3.2'
- rubocop-performance: '1.5.0'
- rubocop-rspec: '1.36.0'
View keybase.md

Keybase proof

I hereby claim:

  • I am rpbaltazar on github.
  • I am rpbaltazar (https://keybase.io/rpbaltazar) on keybase.
  • I have a public key ASCkk3uhB1bExXUnUb4YnBqDtLXY-VRLflilN5x-urUXJQo

To claim this, I am signing this object:

@rpbaltazar
rpbaltazar / Dockerfile
Created Aug 16, 2019
dockerfile and sample docker-compose for whistler services
View Dockerfile
FROM ruby:2.6.3-stretch as base
# WORKDIR needs to be the same as in the final base image or compiled gems will point to an invalid directory
# NOTE: For the compiled gems to be shared across services then the WORKDIR needs to be same for all images
RUN mkdir -p /home/rails/services/app
WORKDIR /home/rails/services/app
ENV BUNDLE_PATH=/bundle \
BUNDLE_BIN=/bundle/bin \
GEM_HOME=/bundle
View Compilation errors
ERROR in ./src/img/plaing_img.png
Module parse failed: Unexpected character '�' (1:0)
You may need an appropriate loader to handle this file type.
(Source code omitted for this binary file)
@ ./node_modules/vue-loader/lib/template-compiler?{"id":"data-v-1d34fbe4","hasScoped":true,"buble":{"transforms":{}}}!./node_modules/vue-loader/lib/selector.js?type=template&index=0!./src/app/containers/ProfilePage/components/Profile.vue 1:4578-4619
@ ./src/app/containers/ProfilePage/components/Profile.vue
@ ./node_modules/babel-loader/lib!./node_modules/vue-loader/lib/selector.js?type=script&index=0!./src/app/containers/ProfilePage/index.vue
@ ./src/app/containers/ProfilePage/index.vue
@ ./src/index.js
View gist:db4c4a5da67f74855b13544594f701e1
"Conns"=>{:name=>"Conns", :part_of_name=>true, :options=>["5-1/2\" (VX54)", "4\" IF (NC46)", "4-1/2\" IF (NC50)", "3-1/2\" IF (NC38)", "5-1/2\" VX54"], :type=>"Single Choice"},
"Clamp"=>{:name=>"Clamp", :part_of_name=>true, :options=>["Manual", "Hydraulic"], :type=>"Single Choice"},
"Conn 1"=>{:name=>"Conn 1", :part_of_name=>true, :options=>["21-1/4\" API 2K", "7-1/16\" API 5K", "10\" ANSI 600 RTJ", "1/4\" NPT Male", "1/2\" NPT male", "13-5/8\" API 5K", "8-5/8\" Reg Box", "4-1/16\" API 5K", "2-1/16\" API 5K", "13-5/8\" API 3K", "2\" ANSI 2500 RTJ", "20-3/4\" API 3K", "13-5/8\" API 10K", "33\" API ?", "3\" NPT Female", "1\" NPT Male", "2\" NPT Male", "2\" Fig 400 Thread", "3\" Fig 400 Thread", "3\" Fig 1502 Thread", "3-1/16\" API 10K", "11\" API 5K", "1/8\" NPT Male"], :type=>"Single Choice"},
"Length"=>{:name=>"Length", :part_of_name=>true, :options=>["m", "ft", "inch"], :type=>"Number"},
"Capacity"=>{:name=>"Capacity", :part_of_name=>true, :options=>["kg", "lbs"], :type=>"Number"},
"Sling Legs"=>{:name=>"Sli
You can’t perform that action at this time.