Skip to content

Instantly share code, notes, and snippets.

View biancarosa's full-sized avatar
💜

bianca rosa biancarosa

💜
View GitHub Profile
@biancarosa
biancarosa / Dockerfile
Created April 19, 2018 00:51
simple-and-small-go-dockerfile
FROM golang:latest AS build
WORKDIR $GOPATH/{your-repo}
COPY . ./
RUN go get github.com/tools/godep
RUN godep get
RUN CGO_ENABLED=0 GOOS=linux go build -a -installsuffix nocgo -o /app .
FROM scratch
COPY --from=build /app ./
# urls.py
from django.conf.urls import url, include
from rest_framework import routers, viewsets
from dashboard_api.views.user import UserViewSet
router = routers.DefaultRouter()
router.register(r'users', UserViewSet)
@biancarosa
biancarosa / settings.json
Created August 31, 2017 16:29
VS Code settings
{
"window.zoomLevel": 0,
"workbench.colorTheme": "Default Light+",
"editor.fontSize": 16,
"editor.fontFamily": "Fira Code",
"editor.fontLigatures": true,
"editor.renderWhitespace": "all"
}
import numpy
print(numpy.arrange(5))
def arrange(n):
print('oi')
return n
@biancarosa
biancarosa / numbers.py
Created August 31, 2017 00:54
Numpy - Arrange
import numpy
numpy.arrange(10)
@biancarosa
biancarosa / numpy.py
Created August 31, 2017 00:53
Numpy - Arrange - Wrong
import numpy
numpy.arrange(10)
@biancarosa
biancarosa / pre-commit
Created August 15, 2017 22:07
Golang fmt - Pre commit
#!/bin/sh
go fmt ./...