Skip to content

Commit

Permalink
feat: WIP initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
edouard-lopez committed Sep 13, 2023
1 parent 643a2ed commit a78277d
Show file tree
Hide file tree
Showing 3 changed files with 39 additions and 0 deletions.
13 changes: 13 additions & 0 deletions foo.exp
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
#!/usr/bin/expect -f

set timeout 1

spawn ./foo.sh

expect "Directory to backup?\r"
send -- "/home/dave/Documents\r"

expect "Backup location?\r"
send -- "/media/dave/external/backup\r"

expect eof
10 changes: 10 additions & 0 deletions foo.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
#!/bin/bash

echo "Directory to backup?"
read source_directory

echo "Backup location?"
read target_directory

echo
echo "Target directory:" $target_directory
16 changes: 16 additions & 0 deletions prompt.exp
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
#!/usr/bin/expect

# docker run \
# --interactive \
# --tty \
# --rm \
# --volume "$pure_project_dir/conf.d/:/nemo/.config/fish/conf.d/" \
# --volume "$pure_project_dir/functions/:/nemo/.config/fish/functions/" \
# purefish/docker-fish:3.5.1
# spawn docker run -it --rm purefish/docker-fish:3.5.1
set timeout 1

spawn fish --command "echo \$pure_version"
# send "echo \$pure_version\r"
expect -re "4.*"
expect eof

0 comments on commit a78277d

Please sign in to comment.