Skip to content

Instantly share code, notes, and snippets.

View sergiocasero's full-sized avatar
😄

Sergio Casero Hernández sergiocasero

😄
View GitHub Profile
@sergiocasero
sergiocasero / project_cleaner.md
Created February 3, 2021 07:42
This is a quite simple script that cleans all your grade/flutter projects inside a folder

Works on linux and macOS (and linux inside Windows)

  1. Download the script (or copy paste it)
  2. Put the script in the same folder than your projects
  3. chmod +x your_script_name.sh, if you didn't change the name => `chmod +x projects_cleaner.sh
  4. ./projects_cleaner.sh
  5. Wait and enjoy!!

If you find this gist helpful, don't forget the star! :)

@sergiocasero
sergiocasero / build.gradle.kts
Last active March 30, 2021 08:13
Add common code to sonarqube analysis
buildscript {
repositories {
// repos
}
dependencies {
// deps
}
}
plugins {
!#/bin/bash
for d in */ ; do
cd $d
if [ -f "pubspec.yaml" ]; then
echo "$d is a flutter project"
flutter clean
else
echo "$d is a gradle project"
./gradlew clean
@sergiocasero
sergiocasero / crontab
Last active September 29, 2022 11:15
A simple, lightweight but powerfull telegram bot that sends your public IP through telegram in case it changes, really useful if you have dynamic IPs but also have a private cloud
# Every minute, perfect for IP_INFO free tier
* * * * * /usr/bin/python3 /PATH_TO_THE_SCRIPT/ipbot.py
test:
stage: test
script:
- ./gradlew test jacocoTestReport
tags:
- docker-L
artifacts:
paths:
- shared/build/reports/jacoco.xml
@sergiocasero
sergiocasero / good_morning.yaml
Last active January 23, 2023 14:34
Good morning Home Asssistant
description: ""
trigger:
- platform: time
at: "08:00:00"
condition: []
action:
- service: notify.telegram
data:
message: >
{# Change these entities with your's #}