Skip to content

Instantly share code, notes, and snippets.

View pzentenoe's full-sized avatar

pzenteno pzentenoe

View GitHub Profile
@pzentenoe
pzentenoe / context_cancel.go
Created June 23, 2020 15:15 — forked from fracasula/context_cancel.go
GoLang exiting from multiple go routines with context and wait group
package main
// Here we show how to properly terminate multiple go routines by using a context.
// Thanks to WaitGroup we'll be able to end all go routines gracefully before the main function ends.
import (
"fmt"
"os"
"context"
"sync"
include: all_lint_rules.yaml
analyzer:
exclude:
- "**/*.g.dart"
- "**/*.freezed.dart"
# This is generated from the i18n vscode extension
- "**/i18n.dart"
strong-mode:
implicit-casts: false
implicit-dynamic: false
@pzentenoe
pzentenoe / flutter_github_ci.yml
Created September 29, 2020 19:39 — forked from rodydavis/flutter_github_ci.yml
Flutter Github Actions Build and Deploy Web to Firebase Hosting, iOS to Testflight, Android to Google Play (fastlane)
name: CI
on:
push:
branches:
- master
pull_request:
branches:
- master
jobs:
build_web:
package main
import (
"fmt"
"io/ioutil"
"net/http"
"sync"
"time"
"go.uber.org/ratelimit"
@pzentenoe
pzentenoe / email.dart
Last active May 27, 2023 16:43 — forked from Klerith/email.dart
Flutter - Formz Inputs
import 'package:formz/formz.dart';
// Define input validation errors
enum EmailError { empty, format }
// Extend FormzInput and provide the input type and error type.
class Email extends FormzInput<String, EmailError> {
static final RegExp emailRegExp = RegExp(
r'^[\w-\.]+@([\w-]+\.)+[\w-]{2,4}$',
@pzentenoe
pzentenoe / license-badges.md
Created July 4, 2024 06:01 — forked from lukas-h/license-badges.md
Markdown License Badges for your Project

Markdown License badges

Collection of License badges for your Project's README file.
This list includes the most common open source and open data licenses.
Easily copy and paste the code under the badges into your Markdown files.

Notes

  • The badges do not fully replace the license informations for your projects, they are only emblems for the README, that the user can see the License at first glance.

Translations: (No guarantee that the translations are up-to-date)