Skip to content

Instantly share code, notes, and snippets.

View LukasBombach's full-sized avatar
👨‍👩‍👧‍👦
Proud father

Lukas Bombach LukasBombach

👨‍👩‍👧‍👦
Proud father
View GitHub Profile
@LukasBombach
LukasBombach / diymore_esp32_lora_espruino_setup.md
Last active July 2, 2024 13:18
Flash diymore ESP32 LoRa with Espruino and show some text on its display

Things that are specific for the diymore ESP32 LoRa in combination with Espruino

  • You need to use this as a Generic ESP32 Device
  • You need to flash the device with a bootloader, partitions and the firmware
  • The baud is 115200

How to

  1. Find out your port
class CompileToStringPlugin {
constructor() {
this.PLUGIN_NAME = this.constructor.name;
}
apply(compiler) {
if (!this.options.isServer) {
compiler.hooks.normalModuleFactory.tap(this.PLUGIN_NAME, nmf => {
nmf.hooks.beforeResolve.tap(this.PLUGIN_NAME, result => {
# nvm with automatic node version switch based on the .nvmrc of a directory
export NVM_DIR="$HOME/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm
autoload -U add-zsh-hook
load-nvmrc() {
local nvmrc_path="$(nvm_find_nvmrc)"
if [ -n "$nvmrc_path" ]; then
local nvmrc_node_version=$(nvm version "$(cat "${nvmrc_path}")")
# My oh my zsh aliases and functions
# Configure oh my zsh
alias zshrc="code ~/.zshrc"
alias pkg="code ./package.json"
alias dev="run dev"
alias build="run build"
alias start="run start"

setting up keyboard controls in recalbox via ssh

  1. plug in keyboard
  2. default controls are
    • arrow keys
    • "start" for menu
    • "a" for select
    • "s" for back
  3. set up network / wifi in the menu, you can see your ip there
  4. ssh root@YOUR_IP, the default password is recalboxroot
use tokio::{runtime::Builder, sync::{mpsc}};
use winit::{event::{Event, WindowEvent}, event_loop::{ControlFlow, EventLoop}, window::{Window, WindowBuilder}};
pub struct Gpu {
pub surface: wgpu::Surface,
pub device: wgpu::Device,
pub queue: wgpu::Queue,
pub sc_desc: wgpu::SwapChainDescriptor,
pub swap_chain: wgpu::SwapChain,
@LukasBombach
LukasBombach / es6.ebnf
Created September 8, 2021 18:27 — forked from avdg/es6.ebnf
ES6 bnf grammer - See https://avdg.github.io/es6.xhtml
/* ebnf file for es 6 - MAY CONTAIN ERRORS / DISAMBIGUITY */
Grammer::= Statement
/* Lexical grammer */
SourceCharacter ::= #x0000-#x10FFFF
InputElementDiv ::= WhiteSpace | LineTerminator | Comment | CommonToken | DivPunctuator | RightBracePunctuator
InputElementRegExp ::= WhiteSpace | LineTerminator | Comment | CommonToken | RightBracePunctuator | RegularExpressionLiteral
InputElementRegExpOrTemplateTail ::= WhiteSpace | LineTerminator | Comment | CommonToken | RegularExpressionLiteral | TemplateSubstitutionTail
InputElementTemplateTail ::= WhiteSpace | LineTerminator | Comment | CommonToken | DivPunctuator | TemplateSubstitutionTail
WhiteSpace ::= "<TAB>" | "<VT>" | "<FF>" | "<SP>" | "<NBSP>" | "<ZWNBSP>" | "<USP>"
  • Go to https://discussions.apple.com/welcome
  • If they forward you to https://communities.apple.com/de/welcome manually remove /de from the url so you'll go to https://communities.apple.com/welcome
  • yes that leaves you with https://communities.apple.com/welcome which is completely different from discussions.apple.com but they should now forward you to https://discussions.apple.com/welcome
  • Sign up with your already existing regular Apple ID
  • You'll need to create a seccond account for the discussion board, but it will be connected to your one and only Apple ID
  • Once you have a emglish discussions account, you will only have two discussions / commuity accounts, but only one Apple ID
  • On both sites you will only ever have to login with your Apple ID from now on
@LukasBombach
LukasBombach / Making Linaria work with Next js.md
Last active February 17, 2022 05:31
Making Linaria work with Next js

add linaria

yarn add -E linaria @zeit/next-css

.babelrc

{
@LukasBombach
LukasBombach / jest.config.json
Last active February 12, 2020 07:47
Debugging Jest with TypeScript in VSCode
{
"preset": "ts-jest",
"testEnvironment": "node"
}