Anagh Kumar BaranwalFixes the rc docs creation65311268 years agoHistory
23 lines · 665 B · Shell
RawDownload
#!/bin/bash# Insert the rc docs into docs/content/rc.md set -e go installmkdir -p /tmp/rclone/cache_testmkdir -p /tmp/rclone/rc_mountexport RCLONE_CONFIG_RCDOCS_TYPE=cacheexport RCLONE_CONFIG_RCDOCS_REMOTE=/tmp/rclone/cache_testrclone -q --rc mount rcdocs: /tmp/rclone/rc_mount &sleep 0.5rclone rc > /tmp/rclone/z.mdfusermount -u -z /tmp/rclone/rc_mount > /dev/null 2>&1 || umount /tmp/rclone/rc_mount awk '    BEGIN       {p=1}    /^<!--- autogenerated start/  {print;system("cat /tmp/rclone/z.md");p=0}    /^<!--- autogenerated stop/   {p=1}    p' docs/content/rc.md > /tmp/rclone/rc.md mv /tmp/rclone/rc.md docs/content/rc.mdrm -rf /tmp/rclone