Skip to content

Instantly share code, notes, and snippets.

View LucJosin's full-sized avatar
🎯
Focusing

Lucas Josino LucJosin

🎯
Focusing
View GitHub Profile
@mnlwldr
mnlwldr / goup.sh
Created March 14, 2024 15:56
Update go to the latest version
#!/bin/sh
RELEASE=$(/usr/local/bin/go list -m -f '{{.Version}}' go@latest)
GO_FILE=go${RELEASE}.linux-amd64.tar.gz
BIN=https://go.dev/dl/${GO_FILE}
echo "download $GO_FILE from $BIN ..."
{
"explorer.fileNesting.enabled": true,
"explorer.fileNesting.patterns": {
"package.json": ".eslint*, prettier*, tsconfig*, vite*, pnpm-lock*, bun.lockb, nest*",
"tailwind.config.js": "tailwind.config*, postcss.config*",
".env.local": ".env*",
".env": ".env*"
}
}
@jcubic
jcubic / cdn.md
Last active June 27, 2024 04:33
How to setup a literally free CDN
@thomaspoignant
thomaspoignant / Makefile
Last active June 24, 2024 22:54
My ultimate Makefile for Golang Projects
GOCMD=go
GOTEST=$(GOCMD) test
GOVET=$(GOCMD) vet
BINARY_NAME=example
VERSION?=0.0.0
SERVICE_PORT?=3000
DOCKER_REGISTRY?= #if set it should finished by /
EXPORT_RESULT?=false # for CI please set EXPORT_RESULT to true
GREEN := $(shell tput -Txterm setaf 2)
@maratori
maratori / .golangci.yml
Last active June 28, 2024 15:03
Golden config for golangci-lint
# This code is licensed under the terms of the MIT license https://opensource.org/license/mit
# Copyright (c) 2021 Marat Reymers
## Golden config for golangci-lint v1.59.1
#
# This is the best config for golangci-lint based on my experience and opinion.
# It is very strict, but not extremely strict.
# Feel free to adapt and change it for your needs.
run:
@aleclarson
aleclarson / rollup-typescript.md
Last active June 21, 2024 03:25
The best Rollup config for TypeScript libraries

Features

🔥 Blazing fast builds
😇 CommonJS bundle
🌲 .mjs bundle
.d.ts bundle + type-checking
🧐 Source maps

Install

# Start from golang base image
FROM golang:alpine as builder
# ENV GO111MODULE=on
# Add Maintainer info
LABEL maintainer="Steven Victor <chikodi543@gmail.com>"
# Install git.
# Git is required for fetching the dependencies.
@bradtraversy
bradtraversy / myscript.sh
Last active June 23, 2024 11:39
Basic Shell Scripting
#! /bin/bash
# ECHO COMMAND
# echo Hello World!
# VARIABLES
# Uppercase by convention
# Letters, numbers, underscores
NAME="Bob"
# echo "My name is $NAME"
@joshbuchea
joshbuchea / semantic-commit-messages.md
Last active June 29, 2024 23:01
Semantic Commit Messages

Semantic Commit Messages

See how a minor change to your commit message style can make you a better programmer.

Format: <type>(<scope>): <subject>

<scope> is optional

Example

@ttscoff
ttscoff / github_toc.rb
Last active January 24, 2023 23:08
A script to generate tables of contents for GitHub readme files
#!/usr/bin/env ruby
# encoding: utf-8
=begin
github_toc v0.2.0
Brett Terpstra 2014
<http://brettterpstra.com/2014/07/01/github-toc-service/>
Creates a linked table of contents from headers in a GitHub readme
Place a [toc] marker in the file to have it automatically replaced with the TOC