Skip to content

Instantly share code, notes, and snippets.

View Zfinix's full-sized avatar
🫡
Build AI Powered Products

Chiziaruhoma Ogbonda Zfinix

🫡
Build AI Powered Products
View GitHub Profile
// SPDX-License-Identifier: UNLICENSED
pragma solidity ^0.8.9;
// Import this file to use console.log
import "hardhat/console.sol"; /// remove this if you are not using hardhat
contract Lock {
uint public unlockTime;
address payable public owner;
class WifiLCDPage extends StatefulWidget {
const WifiLCDPage(this.channel, {Key? key}) : super(key: key);
final Socket? channel;
@override
State<WifiLCDPage> createState() => _WifiLCDPageState();
}
class _WifiLCDPageState extends State<WifiLCDPage> {
#include <LiquidCrystal.h>
#include <ESP8266WiFi.h>
const char *ssid = "TP-Link_58E5";
const char *password = "97001515";
LiquidCrystal lcd(5, 4, 2, 14, 12, 13); // Creates an LC object. Parameters: (rs, enable, d4, d5, d6, d7)
WiFiServer wifiServer(80);
int whichLine = 0;
apply plugin: 'com.android.application'
// define here sign properties
def sPassword = 'storePassword_here'
def kAlias = 'keyAlias_here'
def kPassword = 'keyPassword_here'
android {
...
signingConfigs {
import 'dart:convert';
import 'dart:io';
/// This script finds all i18n Strings and removes multiple instances
void main(List<String> args) async {
Directory? dir;
if (args.isNotEmpty) {
final argPath = args.first;
dir = Directory(argPath);
@Zfinix
Zfinix / main.dart
Last active January 23, 2021 12:25
void main(List<String> args) {
num matchWord(String? orig, String? match) {
if (orig == null || match == null || orig.isEmpty || match.isEmpty) {
return 0;
}
var fromStart = 0.0;
for (var i = 0; i < orig.length && i < match.length; i++) {
if (orig[i] == match[i]) {
fromStart += (1 / orig.length) * 0.5;
}
@Zfinix
Zfinix / main.dart
Last active January 25, 2021 08:40
import 'dart:math' as math;
import 'dart:ui' as ui;
import 'package:flutter/gestures.dart';
import 'package:flutter/material.dart';
import 'package:flutter/rendering.dart';
void main() => runApp(
MaterialApp(
theme: ThemeData.dark(),
This file has been truncated, but you can view the full file.
/*
DAR TIME
It’s a new day - with a new time!
Today you have the possibility to upgrade from 24 to 32 hours in your day. Bringing you the real luxury of more time. Sound good?
Here at Johny Dar, we realise that the real luxury is time.
@Zfinix
Zfinix / dart.yml
Last active December 2, 2020 16:36
name: CI
on:
push:
tags:
- '*'
jobs:
test:
name: Flutter Tests
# place at android/fastlane/Fastfile
desc "Deploy a new beta build to Google Play"
lane :beta do
build_number = number_of_commits()
Dir.chdir "../.." do
sh("flutter", "packages", "get")
sh("flutter", "clean")
sh("flutter", "build", "appbundle", "--build-number=#{build_number}")
end