Compare commits

..

No commits in common. "d7d3aeee39b2742736b5418482443d7d1748ea07" and "52a7cd1d44eed60b82caf960a7d58dafeb67c827" have entirely different histories.

2 changed files with 17 additions and 20 deletions

20
cd-init
View file

@ -1,3 +1,9 @@
# packages
apt-get install --yes \
'rsync' \
'tree' \
# ssh # ssh
mkdir --parents ~/.ssh mkdir --parents ~/.ssh
@ -12,9 +18,13 @@ ssh-ed25519 \
AAAAC3NzaC1lZDI1NTE5AAAAIPHCNcgHlQoiNTXfnUZYvHz9OZwYsmBCrSSV7a7Zche5 AAAAC3NzaC1lZDI1NTE5AAAAIPHCNcgHlQoiNTXfnUZYvHz9OZwYsmBCrSSV7a7Zche5
" > ~/.ssh/known_hosts " > ~/.ssh/known_hosts
# packages # variables
apt-get install --yes \ export SSH_ID='cd'
'python3' \
'rsync' \ export SSH_URL="\
'tree' \ ${SSH_ID}@$(basename ${GITHUB_SERVER_URL})\
:\
/${SSH_ID}/${GITHUB_REF_NAME}/${GITHUB_REPOSITORY}\
"
echo "${SSH_URL}"

View file

@ -1,19 +1,6 @@
[ "${1}" ] || exit
SYNC_HOST="$(basename ${GITHUB_SERVER_URL})"
SYNC_SOURCE="${1}"
SYNC_USER='cd'
SYNC_ROOT="/${SYNC_USER}/${GITHUB_REF_NAME}/${GITHUB_REPOSITORY}"
SYNC_TARGET="${SYNC_USER}@${SYNC_HOST}:${SYNC_ROOT}"
if [ "${2}" ] ; then
SYNC_TARGET="${SYNC_TARGET}/${2}"
fi
#rsync \ #rsync \
#--archive \ #--archive \
#--delete-before \ #--delete-before \
#--verbose \ #--verbose \
echo "${SYNC_SOURCE}/" #'out/' \
echo "${SYNC_TARGET}/" echo "${SSH_URL}/"