Skip to content

Instantly share code, notes, and snippets.

View the-spanish-guy's full-sized avatar
:octocat:
Working from home

Luis Enrique the-spanish-guy

:octocat:
Working from home
View GitHub Profile
@the-spanish-guy
the-spanish-guy / ytdl.sh
Created October 27, 2023 02:10
download best video format + best audio format
youtube-dl -f 'bestvideo[ext=mp4]+bestaudio[ext=m4a]/bestvideo+bestaudio' --merge-output-format mp4 link-here
find . -name '*.*:Zone.Identifier' -delete
@the-spanish-guy
the-spanish-guy / .cz-config.js
Created February 7, 2022 00:15
config for cz-customizable
module.exports = {
types: [
{ value: ':sparkles: feat', name: '✨ feat:\tAdding a new feature' },
{ value: ':bug: fix', name: '🐛 fix:\tFixing a bug' },
{ value: ':memo: docs', name: '📝 docs:\tAdd or update documentation' },
{
value: ':lipstick: style',
name: '💄 style:\tAdd or update styles, ui or ux'
},
{
@the-spanish-guy
the-spanish-guy / measures.tsx
Created November 30, 2021 13:23
get width and height from window (mobile/web))
import { useState, useEffect, ReactElement } from 'react'
// Usage
const App = (): ReactElement => {
const size = useWindowSize()
return <div>{size.width}</div>
}
@the-spanish-guy
the-spanish-guy / get-dimensions-from-window.tsx
Last active November 8, 2021 12:48
create a custom hook to get dimensions from actually window in nextjs.
import { useState, useEffect, ReactElement } from 'react'
// Usage
const App = (): ReactElement => {
const size = useWindowSize()
return <div>{size.width}</div>
}
@the-spanish-guy
the-spanish-guy / .editorconfig
Created October 24, 2021 20:30
.editorconfig
# EditorConfig is awesome: https://EditorConfig.org
# top-most EditorConfig file
root = true
[*]
indent_style = space
indent_size = 2
end_of_line = lf
charset = utf-8
@the-spanish-guy
the-spanish-guy / .prettierrc
Last active October 24, 2021 20:29
.prettierrc
{
"semi": false,
"trailingComma": "none",
"arrowParens": "avoid",
"singleQuote": true,
"tabWidth": 2,
"printWidth": 100,
"endOfLine": "auto"
}
@the-spanish-guy
the-spanish-guy / .eslintrc
Last active October 24, 2021 20:30
.eslintrc
{
"env": {
"browser": true,
"es2021": true,
"node": true,
"jest": true
},
"extends": ["standard", "plugin:@typescript-eslint/recommended"],
"parser": "@typescript-eslint/parser",
"parserOptions": {
//path: /usr/share/vscodium-bin/resources/app/product.json -- arch based
//path: /snap/codium/151/usr/share/codium/resources/app/product.json -- snap install
//change vscodium
"extensionsGallery": {
"serviceUrl": "https://open-vsx.org/vscode/gallery",
"itemUrl": "https://open-vsx.org/vscode/item"
}
//to vscode
@the-spanish-guy
the-spanish-guy / logsInsight
Last active February 10, 2022 14:09
query pra consulta de um texto especifico dentro de um log no cloudwatch(Logs Insights) aws
fields @timestamp, @message, @logStream
| filter @message like /texto a procurar/
| sort @timestamp desc
| limit 20