Skip to content

Commit

Permalink
fix(layout): update the Zellij layout to use KDL format (#3)
Browse files Browse the repository at this point in the history
  • Loading branch information
orhun committed Nov 25, 2023
1 parent f5319db commit eba365f
Showing 1 changed file with 11 additions and 15 deletions.
26 changes: 11 additions & 15 deletions alpkg
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ create-pkg-script() {
pkg=""
lint_pkg=false
edit_pkg=true
layout_file="$PACKAGE_DIR/pkg-edit-layout.yml"
layout_file="$PACKAGE_DIR/pkg-edit-layout.kdl"
while getopts ":lhe" opt; do
case ${opt} in
e)
Expand Down Expand Up @@ -83,20 +83,16 @@ create-pkg-script() {
}

create-zellij-layout() {
cat <<-'_EOF_' >"$CHROOT_DIR/$PACKAGE_DIR/pkg-edit-layout.yml"
# https://zellij.dev/old-documentation/layouts.html
tabs:
- direction: Vertical
parts:
- direction: Vertical
focus: true
split_size:
Percent: 50
run:
command: { cmd: vim, args: ["APKBUILD"] }
- direction: Vertical
split_size:
Percent: 50
cat <<-'_EOF_' >"$CHROOT_DIR/$PACKAGE_DIR/pkg-edit-layout.kdl"
// https://zellij.dev/documentation/layouts
layout {
pane split_direction="vertical" {
pane focus=true command="vim" {
args "APKBUILD"
}
pane
}
}
_EOF_
}

Expand Down

0 comments on commit eba365f

Please sign in to comment.