Skip to content

Commit

Permalink
generate all keyboard layouts
Browse files Browse the repository at this point in the history
  • Loading branch information
andreineculau committed Nov 11, 2021
1 parent 3665406 commit 05ffc6c
Show file tree
Hide file tree
Showing 611 changed files with 723,799 additions and 9 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
/*.deb
/usr/
/tmp/
22 changes: 13 additions & 9 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,19 @@ XKB_DATA_URL=http://ports.ubuntu.com/pool/main/x/xkeyboard-config/${XKB_DATA_DEB
all: ${XKB_DATA_DEB}
ar -x ${XKB_DATA_DEB} ./data.tar.xz
tar xvf data.tar.xz
rm data.tar.xz
rm -f Makefile.log
for f in usr/share/X11/xkb/symbols/??; do \
./klfc $$f --from-xkb --keylayout ./ 2>>Makefile.log; \
f_basename=$$(basename $$f); \
sed -i "s/name=\"[^\"]\+\"/name=\"ysoftwareab xkb $${f_basename}\"/" $${f_basename}.keylayout; \
mv $${f_basename}.keylayout y-xkb-$${f_basename}.keylayout; \
done
rm install-{user,system}.sh
rm -rf data.tar.xz tmp Makefile.log
( for f in usr/share/X11/xkb/symbols/??; do \
for g in $$(cat $$f | grep "^xkb_symbols" | sed "s/^xkb_symbols \+\"\([^\"]\+\)\".*/\1/"); do \
./klfc --from-xkb "$$f($$g)" --keylayout ./tmp; \
f_basename=$$(basename $$f); \
g_suffix="-$$g"; \
[[ "$$g" != "basic" ]] || g_suffix=; \
echo y-xkb-$${f_basename}$${g_suffix}.keylayout; \
mv tmp/$${f_basename}$${g_suffix}.keylayout y-xkb-$${f_basename}$${g_suffix}.keylayout; \
sed -i "s/name=\"[^\"]\+\"/name=\"ysoftwareab xkb $${f_basename}$${g_suffix}\"/" y-xkb-$${f_basename}$${g_suffix}.keylayout; \
done; \
done ) 2>>Makefile.log
rm -rf tmp

${XKB_DATA_DEB}:
curl -O ${XKB_DATA_URL}
Loading

0 comments on commit 05ffc6c

Please sign in to comment.