Skip to content

Instantly share code, notes, and snippets.

View Davenchy's full-sized avatar

Davenchy Davenchy

View GitHub Profile
@psygo
psygo / reflection_and_annotations.md
Last active November 29, 2024 21:16
Reflection and Annotations in Dart

Reflection in Dart

Unfortunately, [since mirrors currently bloat compiled code][no_support_mirrors], it isn't supported for Flutter or web apps. A [workaround][source_gen_tutorial] would be to use a package like [source_gen][source_gen].

dart:mirrors

Most of the info here, comes from [Understanding Reflection and Annotations in Dart tutorial][reflection_tutorial], from the Fullstack Dart and Flutter Tutorials YouTube channel. He also created a [gist][gist_tutorial] with it.

@vinicioslc
vinicioslc / flutter-android-cd.yml
Last active November 20, 2024 15:53
Build flutter releases in github actions for production only android for while.
# This is a basic workflow to help you get started with Actions
name: CD Internal-Lane
# Controls when the action will run. Triggers the workflow on push or pull request
# events but only for the master branch
on:
push:
tags:
- "internal-v*.*.*" # on every version tag will build a new android artifact example: v3.1.2+6
jobs:
@syntaxhacker
syntaxhacker / Flutterinstallwithoutandroidstudio.md
Last active April 25, 2025 21:17
setup flutter without android studio

Flutter install without android studio

set flutter

Download flutter

tar xvf flutter_linux_1.17.5-stable.tar.xz

@JacquesLucke
JacquesLucke / llvm_add.cc
Created November 30, 2018 14:54
Compile simple add function using the LLVM C++ API.
#include "llvm/IR/IRBuilder.h"
#include "llvm/IR/Verifier.h"
#include "llvm/Support/TargetSelect.h"
#include "llvm/ExecutionEngine/ExecutionEngine.h"
#include <vector>
#include <memory>
void test_llvm() {
llvm::LLVMContext *context = new llvm::LLVMContext();
@c4software
c4software / download-multiple-files.js
Created June 6, 2018 08:56 — forked from noelvo/download-multiple-files.js
Download multiple files then compress to one zip file using JSZip & JSZip-utils
var zip = new JSZip();
var count = 0;
var zipFilename = "zipFilename.zip";
var urls = [
'http://image-url-1',
'http://image-url-2',
'http://image-url-3'
];
urls.forEach(function(url){
@fakhrullah
fakhrullah / list-of-hacking-games.md
Last active September 27, 2024 01:20
List of hacking game, wargame or capture the flag (CTF) for some one who want to learn hacking.
// We allocate a file with the size of the downloaded file so we can
// append chunks randomly to diffrent position as we download the file
function allocateDisk(size, callback){
fss.cwd.getFile(prompt("Filename","movie.mp4"), {create: true}, (fileEntry) => {
fileEntry.createWriter((writer) => {
var blob = new Blob([new ArrayBuffer(1.049e+8)])
writer.onerror = (err) => {
@dreadpiratesr
dreadpiratesr / [PYTHON]
Last active April 8, 2022 03:23
Facebook Reset Code 0day Python Version
#Facebook Reset Code 0day Python Version
#If you want to edit this script you are free i don't give a fuck cause it tooks 2 minutes to write xD \!/
#As a temporarily solution, use requesocks Module
#How to install?
#with pip : pip install requesocks
#with easy_install : easy_install requesocks
import urllib2 ,sys ,re
import os
import ssl
@racerxdl
racerxdl / measure.py
Created September 18, 2014 06:07
Linux Network Traffic Measure/Calculator Python Script
#!/usr/bin/env python
'''
_______ ______
|_ _\ \ / / ___|
| | \ \ / /\___ \
| | \ V / ___) |
|_| \_/ |____/
Teske Virtual System
@AnnaGerber
AnnaGerber / 11_piezo.py
Last active October 16, 2022 13:51
PyFirmata code for Freetronics Experimenter's Kit
import pyfirmata
import math
board = pyfirmata.Arduino("/dev/ttyACM0")
# connect piezo to pin 9 to use PWM
SENSOR_PIN = 0
PIEZO_PIN = board.get_pin('d:9:p')
it = pyfirmata.util.Iterator(board)