Skip to content

Instantly share code, notes, and snippets.

View mcepl's full-sized avatar

Matěj Cepl mcepl

View GitHub Profile
@mcepl
mcepl / container-syncthing.service
Created May 20, 2023 11:28
Converting container-*.service to *.container
[Unit]
Description=Podman container-syncthing.service
Documentation=https://github.com/syncthing/syncthing/blob/main/README-Docker.md \
https://docs.syncthing.net/intro/getting-started.html#getting-started
Wants=network-online.target
After=network-online.target
RequiresMountsFor=%t/containers
[Service]
Environment=PODMAN_SYSTEMD_UNIT=%n
-- TODO: show current hunk in status line
-- TODO: incorporate more patchutils functionality
-- FIXME https://www.reddit.com/r/neovim/comments/unwvkw/github_hkuptyrunesnvim_lua_test_framework_for/
-- FIXME https://github.com/hkupty/runes.nvim
pretty = require("pl.pretty")
local M = {}
@mcepl
mcepl / working-nonworking-lexer.patch
Created February 16, 2023 14:17
Diff between /usr/share/vis/lexers/lexer.lua (working with vis) and ~/repos/tmp/scintillua/lexers/lexer.lua (not working from 2181945 here)
--- /usr/share/vis/lexers/lexer.lua 2023-02-16 14:48:12.000000000 +0100
+++ /home/matej/repos/tmp/scintillua/lexers/lexer.lua 2023-02-15 16:11:42.268436415 +0100
@@ -1,23 +1,21 @@
--- Copyright 2006-2022 Mitchell. See LICENSE.
+-- Copyright 2006-2023 Mitchell. See LICENSE.
-local M = {}
-
---[=[ This comment is for LuaDoc.
---
@mcepl
mcepl / scintillua-vis_lexers.diff
Last active November 30, 2022 10:27
Diff between default branch of scintillua lexers and master branch of vis
diff -uNr /home/matej/repos/tmp/scintillua/lexers/actionscript.lua lexers/actionscript.lua
--- /home/matej/repos/tmp/scintillua/lexers/actionscript.lua 2022-11-30 11:15:03.673970821 +0100
+++ lexers/actionscript.lua 2022-11-29 23:51:43.326328927 +0100
@@ -53,8 +53,7 @@
-- Fold points.
lex:add_fold_point(lexer.OPERATOR, '{', '}')
lex:add_fold_point(lexer.COMMENT, '/*', '*/')
+lex:add_fold_point(lexer.COMMENT, lexer.fold_consecutive_lines('//'))
lex:add_fold_point(lexer.STRING, '<![CDATA[', ']]>')
(gdb) b config_init_int_max_str_digits
Function "config_init_int_max_str_digits" not defined.
Make breakpoint pending on future shared library load? (y or [n]) y
Breakpoint 1 (config_init_int_max_str_digits) pending.
(gdb) run
Starting program: /home/abuild/rpmbuild/BUILD/Python-3.6.15/python -X faulthandler -X int_max_str_digits=7000
Missing separate debuginfos, use: zypper install glibc-debuginfo-2.36-6.1.x86_64
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib64/libthread_db.so.1".
stitny~/r/t/python-xmlsec (master)$ python3.10 -mvenv .
stitny~/r/t/python-xmlsec (master)$ source bin/activate.fish
(python-xmlsec) stitny~/r/t/python-xmlsec (master)$ python3.10 -mpip install -r requirements-test.txt
Collecting lxml!=4.7.0,>=3.8.0
Using cached lxml-4.8.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_24_x86_64.whl (7.0 MB)
Collecting pytest>=4.6.9
Downloading pytest-7.1.2-py3-none-any.whl (297 kB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 297.0/297.0 KB 1.4 MB/s eta 0:00:00
Collecting hypothesis
Downloading hypothesis-6.46.7-py3-none-any.whl (384 kB)
http://carlmedearis.com/feed/
https://goddidntsaythat.com/feed/
https://hacks.mozilla.org/feed/
https://unumnecessariumdotorg.wordpress.com/feed/
https://www.firstthings.com/rss/web-exclusives
https://planetpython.org/rss20.xml
http://neopythonic.blogspot.com/feeds/posts/default
http://mypy-lang.blogspot.com/feeds/posts/default
https://www.thepublicdiscourse.com/feed/
https://www.patheos.com/blogs/anxiousbench/author/philipjenkins/feed/
stitny/t/xmlsec-1.3.12$ gdb python3.10
GNU gdb (GDB; openSUSE Tumbleweed) 11.1
Copyright (C) 2021 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Type "show copying" and "show warranty" for details.
This GDB was configured as "x86_64-suse-linux".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
neovim@stitny (vim-8.2.3520 *)$ git diff
diff --git a/src/nvim/edit.c b/src/nvim/edit.c
index 02ac62574..3ea7b442c 100644
--- a/src/nvim/edit.c
+++ b/src/nvim/edit.c
@@ -2545,7 +2545,7 @@ static void ins_compl_longest_match(compl_T *match)
* Add an array of matches to the list of matches.
* Frees matches[].
*/
-static void ins_compl_add_matches(int num_matches, char_u * *matches, int icase)