Skip to content

Instantly share code, notes, and snippets.

View IgorDePaula's full-sized avatar
😆

Igor C. de Paula IgorDePaula

😆
View GitHub Profile
@IgorDePaula
IgorDePaula / uploadMultipart.native.ts
Created January 6, 2025 01:50 — forked from ahartzog/uploadMultipart.native.ts
Alek's Multipart Upload
import apiFetch from 'modules/api-fetch';
import Toast from 'modules/toast/index.native';
import Sentry from 'modules/sentry';
const FILE_CHUNK_SIZE = 5242880;
const uploadMultipart = async (
file: string,
setIsUploading = (set: boolean) => {},
setUploadProgress = (set: number) => {},
@IgorDePaula
IgorDePaula / calendar.html
Created July 23, 2024 23:46 — forked from eminkel/calendar.html
calendar-tailwind-alpinejs
<body class="antialiased sans-serif bg-gray-100">
<div x-data="app()" x-init="[initDate(), getNoOfDays()]" x-cloak>
<div class="container mx-auto px-4 py-2 md:py-24">
<!-- <div class="font-bold text-gray-800 text-xl mb-4">
Schedule Tasks
</div> -->
<div class="bg-white rounded-lg shadow overflow-hidden">
<?php
/**
* Reference:
* - http://www.libnfc.org/api/examples_page.html
* - https://github.com/nfc-tools/libnfc/blob/master/examples/nfc-poll.c
*
* Tested:
* - PaSoRi RC-S330
*
* Example Output:
@IgorDePaula
IgorDePaula / index.html
Created February 9, 2024 01:49 — forked from aschmelyun/index.html
In AR.js display a video which transitions into an image on completion
<!DOCTYPE html>
<html>
<head>
<title>AR Demo</title>
<script src="https://aframe.io/releases/0.6.1/aframe.min.js"></script>
<script src="https://jeromeetienne.github.io/AR.js/aframe/build/aframe-ar.js"></script>
<script src="https://code.jquery.com/jquery-3.3.1.min.js" integrity="sha256-FgpCb/KJQlLNfOu91ta32o/NMZxltwRo8QtmkMRdAu8=" crossorigin="anonymous"></script>
<meta name="apple-mobile-web-app-capable" content="yes">
<script>
// We're going to register a custom event listener through a-frame that will fire
@IgorDePaula
IgorDePaula / README.md
Created January 1, 2024 02:14 — forked from shankarshastri/README.md
Setup lambda + API Gateway using localstack
@IgorDePaula
IgorDePaula / LaravelWhereLikeMacro.php
Created November 26, 2023 13:15 — forked from MrPunyapal/LaravelWhereLikeMacro.php
Laravel Custom 'whereLike' Macro for Dynamic 'LIKE' Searches including relationships
<?php
use Illuminate\Support\ServiceProvider;
use Illuminate\Database\Eloquent\Builder;
use Illuminate\Support\Arr;
class AppServiceProvider extends ServiceProvider
{
// ...
@IgorDePaula
IgorDePaula / post-receive.sh
Created October 21, 2023 17:33 — forked from lfalmeida/post-receive.sh
Hook post receive com push options
#!/bin/sh
# ---- Config
ENV_NAME="Homologação"
TAG_SUFFIX="homolog"
PROJECT_NAME="Scania Journey Event"
PROJECT_PATH_HOST="/home/lfalmeida/Projects/GitHooks/prod/"
PROJECT_PATH_DOCKER="/src/projeto"
SLACK_WEBHOOK=""
ENABLE_SLACK_POST=0
openssl genrsa 2048 > private.pem
openssl req -x509 -new -key private.pem -out public.pem
openssl pkcs12 -export -in public.pem -inkey private.pem -out mycert.pfx
@IgorDePaula
IgorDePaula / git-reset-author.sh
Created May 11, 2023 13:39 — forked from bgromov/git-reset-author.sh
Git: reset author for ALL commits
#!/bin/sh
# Credits: http://stackoverflow.com/a/750191
git filter-branch -f --env-filter "
GIT_AUTHOR_NAME='Newname'
GIT_AUTHOR_EMAIL='new@email'
GIT_COMMITTER_NAME='Newname'
GIT_COMMITTER_EMAIL='new@email'
" HEAD
@IgorDePaula
IgorDePaula / Esconder_console_log.md
Created March 15, 2023 02:01 — forked from romuloctba/Esconder_console_log.md
Esconder console.log() quando o site for para produção

Esconder console.log() para o site em produção

  • Trocar o www.mywebsite.com pelo endereço do site em produção;
  • Incluir isso no início do seu script.

Se passar o parâmetro ?development na URL, ele ignora e mostra os console.log().