Skip to content

Instantly share code, notes, and snippets.

View JakubAndrysek's full-sized avatar

Kuba Andrýsek JakubAndrysek

View GitHub Profile
@JakubAndrysek
JakubAndrysek / FlaskServer.py
Last active September 10, 2024 18:26
ChatGPT - plugin actions + Python Flask backend
from flask import Flask, request, jsonify
import random
app = Flask(__name__)
data = {}
@app.route('/')
def home():

Nextbike API

List citie

https://maps.nextbike.net/maps/nextbike-official.json?list_cities=1

Live data from City (uid: 660 = Brno)

@JakubAndrysek
JakubAndrysek / limit-google-form-responses.js
Last active April 16, 2024 21:23
This Google Apps Script code will automatically close a Google Form when it reaches a maximum number of responses. It will also send an email notification to the form owner when the limit is reached.
/**
* Google Apps Script code to close a Google Form when it reaches a maximum number of responses.
* Author: Jakub Andrýsek
* Website: https://kubaandrysek.cz
* Email: email@kubaandrysek.cz
* GitHub: https://github.com/JakubAndrysek
* License: MIT
* File: https://gist.github.com/JakubAndrysek/fbcdf78f7bc91d905d22350e7cbcdb31
*/
@JakubAndrysek
JakubAndrysek / Setup PHP Xdebug on Mac M1 with PhpStorm.md
Last active April 16, 2024 19:53
Setup PHP Xdebug on Mac M1 with PhpStorm

Setup PHP Xdebug on Mac M1 with PhpStorm

  • Install PHP
  • brew install php
@JakubAndrysek
JakubAndrysek / AppsRunningMac.scpt
Last active April 16, 2024 19:50
Get JSON of running apps + paths on macOS
-- Get JSON of runnin apps + paths on macOS
-- Author: JakubAndrysek + (https://www.alfredforum.com/topic/11318-solved-how-to-load-an-applications-icon-with-applescript/?do=findComment&comment=59154)
-- Version: 1.0
-- License: MIT
-- Link: https://gist.github.com/JakubAndrysek/2f4f4de69443fc0438ddb6320caf2349
-- Description: This script lists all running non-background processes and their paths in JSON format.
tell application "System Events"
set runningProcesses to (every process whose background only is false)
@JakubAndrysek
JakubAndrysek / yabai-update.py
Last active April 16, 2024 19:51
Yabai - Configure scripting addition - automation
#!/usr/bin/env python3
# Yabai - Configure scripting addition - automation
# Author: Jakub Andrysek
# Website: https://kubaandrysek.cz
# License: MIT
# GitHub: https://github.com/JakubAndrysek
# https://github.com/koekeishiya/yabai/wiki/Installing-yabai-(latest-release)#configure-scripting-addition
import os
@JakubAndrysek
JakubAndrysek / CopyGoogleSharedDrive.gs
Last active May 29, 2024 11:02
Copying files and folders from a personal Google Drive to a Shared Google Drive (aka Team Drives) using Google Apps Script
/**
* Copying files and folders from a personal Google Drive to a Shared Google Drive (aka Team Drives) using Google Apps Script
* Author: Jakub Andrýsek + https://stackoverflow.com/users/8199076/azmol
* Website: https://kubaandrysek.cz
* Email: email@kubaandrysek.cz
* GitHub: https://github.com/JakubAndrysek
* License: MIT
* File: https://gist.github.com/JakubAndrysek/d3c16b85bf34eaca18d33df471104dd5
*/
@JakubAndrysek
JakubAndrysek / ZebraPrint-UNIX.md
Last active October 21, 2023 13:31
Add Zebra printer to UNIX + print from Inkscape / Terminal
@JakubAndrysek
JakubAndrysek / PyQt-BLE.py
Last active July 30, 2023 10:35
Gattol + HciTool
# not work during my test
import sys
from PyQt5.QtBluetooth import QBluetoothLocalDevice, QBluetoothDeviceDiscoveryAgent, QBluetoothDeviceInfo, QLowEnergyController, QBluetoothUuid, QLowEnergyService
from PyQt5.QtCore import QObject, QCoreApplication, pyqtSlot
class BLEApp(QObject):
def __init__(self, parent=None):
super(BLEApp, self).__init__(parent)
self.deviceAddress = "E5:76:86:2B:B4:F8"