Skip to content

Instantly share code, notes, and snippets.

View lempiy's full-sized avatar

Anton Lempiy lempiy

View GitHub Profile
{
"name":"Cry Meme #1",
"symbol":"CRME",
"description":"My face when I'm doing my first NFT. ",
"seller_fee_basis_points":1,
"external_url":"",
"edition":"Class of 2022",
"background_color":"000000",
"attributes":[
{
{
"cluster": {
"peername": "cluster2",
"secret": "",
"leave_on_shutdown": false,
"listen_multiaddress": [
"/ip4/0.0.0.0/tcp/9096",
"/ip4/0.0.0.0/udp/9096/quic"
],
"enable_relay_hop": true,
@lempiy
lempiy / gyromath.dart
Created November 25, 2021 08:39
Gyro
import 'dart:math';
const int AXIS_X = 1;
const int AXIS_Y = 2;
const int AXIS_Z = 3;
const int AXIS_MINUS_X = AXIS_X | 0x80;
const int AXIS_MINUS_Y = AXIS_Y | 0x80;
const int AXIS_MINUS_Z = AXIS_Z | 0x80;
abstract class Gyromath {
class AppInSessionState extends StatelessWidget {
final Widget child;
const AppInSessionState({Key key, this.child}) : super(key: key);
@override
Widget build(BuildContext context) {
final sessionBloc = Provider.of<SessionBloc>(context);
return BlocProvider<AuthorBloc>(
builder: (_, bloc) => bloc ?? AuthorBloc(sessionBloc, AuthorApi()),
onDispose: (_, bloc) => bloc.dispose(),
@lempiy
lempiy / entity.json
Last active September 16, 2019 13:11
preset
{
"data": {
"customer_details": [
{
"name": "email",
"type": "email",
"length": 254,
"default_value": "",
"use_in_payload": true,
"is_required": false,
const source = [
{
id: "A",
next: ["B"]
},
{
id: "B",
next: ["C", "D", "E", "F", "M"]
},
{
// LimitWaitGroup - is the special kind of Wait Group.
// It works similar to sync.WaitGroup with Add and Done methods,
// but instead of Wait method it brings InsureLimit method.
// InsureLimit - will block the thread if pending
// proccesses counter breaks to provided threshold (limit) count
// Also SetLimit method allows dynamic change of group limit
type LimitWaitGroup struct {
limit int
count int
cond *sync.Cond
/*
* File: bst.js
*
* A pure JavaScript implementation of a binary search tree.
*
*/
/*
* Class: BST
*
@lempiy
lempiy / find.js
Last active April 21, 2019 20:51
(()=> {
const submit = document.querySelector('#search-frm button[type="submit"]')
const utterThis = new SpeechSynthesisUtterance('Found ticket');
const id = setInterval(() => {
const table = document.querySelector('#train-list .train-table')
if (!table) {
submit.click()
return
}
console.log(table)
@lempiy
lempiy / fixSQLite.go
Created April 26, 2018 10:01
fixSQLite
package main
import (
"os/exec"
"fmt"
"time"
)
func main() {
var newDbName string