Skip to content

Instantly share code, notes, and snippets.

View vadimreutskiy's full-sized avatar

Vadim Reutskiy vadimreutskiy

  • Remy Robotics
  • Barcelona, Spain
View GitHub Profile
@vadimreutskiy
vadimreutskiy / send_external_ip_to_telegram.py
Last active April 15, 2023 23:17
Get external IP of the current machine from one of the services and send it to the Telegram chat using bot API
# Script initially generated by ChatGPT with GPT-4 and manually modified in some details
import requests
import os
import socket
import logging
import smtplib
from email.message import EmailMessage
from typing import Tuple, Optional
@vadimreutskiy
vadimreutskiy / cmd_change_layout.json
Created February 22, 2023 09:20
Karabiner elements configuration for changing input layout by pressing CMD keys
{
"title": "Change keyboard layout on cmd press",
"rules": [
{
"description": "Change input source to En (ABC) left_command; Ru by right_command.",
"manipulators": [
{
"type": "basic",
"from": {
"key_code": "left_command",
accept:44, StudentIdPresenter$onStudentIdFilled$2 (jp.co.soramitsu.feature_registration_impl.presentation.student_id)
accept:12, StudentIdPresenter$onStudentIdFilled$2 (jp.co.soramitsu.feature_registration_impl.presentation.student_id)
onError:46, ConsumerSingleObserver (io.reactivex.internal.observers)
run:79, SingleObserveOn$ObserveOnSingleObserver (io.reactivex.internal.operators.single)
run:119, HandlerScheduler$ScheduledRunnable (io.reactivex.android.schedulers)
handleCallback:751, Handler (android.os)
dispatchMessage:95, Handler (android.os)
loop:154, Looper (android.os)
main:6119, ActivityThread (android.app)
invoke:-1, Method (java.lang.reflect)