Skip to content

Instantly share code, notes, and snippets.

View rku4er's full-sized avatar
🌍
Working from home

Roman K rku4er

🌍
Working from home
  • Ukraine
View GitHub Profile
@rku4er
rku4er / parse-wp-blocks-recursive.php
Last active July 7, 2024 00:28
Custom utils for retrieving blocks from Wordpress posts content, archives, search, 404, etc.
<?php
/**
* Recursively get blocks and their inner blocks.
*
* @param array $blocks List of blocks.
* @return array Flattened list of all blocks.
*/
function get_blocks_recursive( array $blocks ) {
$result = [];
@rku4er
rku4er / 300-most-commonly-used-british-english-words-with-different-american-english-spelling.txt
Created April 9, 2024 21:20
300 most commonly used British English words with different American English spelling (built with ChatGPT 3.5)
Colour - Color
Favourite - Favorite
Centre - Center
Theatre - Theater
Travelling - Traveling
Flavour - Flavor
Honour - Honor
Defence - Defense
Analyse - Analyze
Organisation - Organization
@rku4er
rku4er / minecraft-1.19.2.log
Created March 16, 2024 01:50
Minecraft 1.19.2 log
[04:14:57] [Server thread/INFO]: Starting integrated minecraft server version 1.19.2
[04:14:57] [Server thread/INFO]: Generating keypair
[04:14:58] [Server thread/INFO]: Preparing start region for dimension minecraft:overworld
[04:15:01] [Render thread/INFO]: Preparing spawn area: 0%
[04:15:01] [Render thread/INFO]: Preparing spawn area: 0%
[04:15:01] [Render thread/INFO]: Preparing spawn area: 0%
[04:15:01] [Render thread/INFO]: Preparing spawn area: 0%
[04:15:01] [Render thread/INFO]: Preparing spawn area: 0%
[04:15:01] [Render thread/INFO]: Preparing spawn area: 0%
[04:15:01] [Render thread/INFO]: Preparing spawn area: 0%
@rku4er
rku4er / .vimrc
Created September 11, 2020 03:08
Deoplete + Neosnippets
" deoplete {
if count(g:spf13_bundle_groups, 'deoplete')
let g:deoplete#enable_at_startup = 1
let g:deoplete#enable_ignore_case = 1
let g:neosnippet#enable_completed_snippet = 1
" ----------------------------------------------------------------------------
" supertab & neosnippet
" ----------------------------------------------------------------------------
imap <C-k> <Plug>(neosnippet_expand_or_jump)
smap <C-k> <Plug>(neosnippet_expand_or_jump)
@rku4er
rku4er / WinUSBFromLinux.md
Created March 9, 2020 03:13
How to make Windows 7 USB flash install media from Linux?

How to make Windows 7 USB flash install media from Linux?

StackOverflow

  • Install ms-sys - if it is not in your repositories, get it here. Or alternatively, make sure lilo is installed (but do not run the liloconfig step on your local box if e.g. Grub is installed there!)
  • Check what device your USB media is assigned - here we will assume it is /dev/sdb. Delete all partitions, create a new one taking up all the space, set type to NTFS (7), and remember to set it bootable:
# cfdisk /dev/sdb
or fdisk /dev/sdb (partition type 7, and bootable flag)