Skip to content

Instantly share code, notes, and snippets.

View proteye's full-sized avatar
🏠
Working from home

Ramil Zaynetdinov proteye

🏠
Working from home
View GitHub Profile
@proteye
proteye / bitwarden_passwords_fix.js
Created June 29, 2024 12:17
Fix names of Bitwarden passwords
const fs = require("fs");
const url = require("url");
function fixBitwardenJson() {
const filePath = process.argv[2];
if (!filePath || !fs.existsSync(filePath)) return;
let jsonData = null;
let count = 0;
@proteye
proteye / check_internet_connection.dart
Created July 18, 2024 13:10
Check internet connection on Flutter
import 'dart:developer' as developer;
import 'dart:io';
const _lookupHost = 'example.com';
/// Web servers to check.
const _hosts = [
'example.com',
'ya.ru',
'google.com',
@proteye
proteye / inherited_model_sample.dart
Created August 28, 2024 16:40 — forked from PlugFox/inherited_model_sample.dart
SettingsScope with InheritedModel
/*
* https://gist.github.com/PlugFox/320d051c5a393f56f60c3cf080d6171a
* https://dartpad.dev/320d051c5a393f56f60c3cf080d6171a?null_safety=true
*/
import 'package:flutter/widgets.dart';
@immutable
class SettingsScope extends StatefulWidget {
final Widget child;