aboutsummaryrefslogtreecommitdiff
path: root/fix-dotfile-paths.sh
diff options
context:
space:
mode:
Diffstat (limited to 'fix-dotfile-paths.sh')
-rwxr-xr-xfix-dotfile-paths.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/fix-dotfile-paths.sh b/fix-dotfile-paths.sh
index ce62627..450d1c2 100755
--- a/fix-dotfile-paths.sh
+++ b/fix-dotfile-paths.sh
@@ -19,7 +19,7 @@ create_ls_entry () {
if [ "$file" = ".wallpaper" ]; then
echo "- [[https://wallhaven.cc/w/vgryy5][=.wallpaper=]]" >> index.org
elif echo "$file" | grep -q "\.org$" && [ "$file" != "index.org" ]; then
- new_file=$(basename "$(grep '#+begin_src' "$file" | head -1 | cut -d ' ' -f 4)")
+ new_file=$(echo "$file" | sed 's/\.org$//')
html=$(echo "$file" | sed 's/\.org$/\.html/')
echo "- [[$2$1$html][=$new_file=]]" >> index.org
fi