Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- {"hash": "79e7b189ab3985f4bf753ba706da07ed", "thumb_exists": false, "bytes": 0, "path": "/", "is_dir": true, "size": "0 bytes", "root": "app_folder", "contents": [{"revision": 135, "rev": "8714372dc4", "thumb_exists": false, "bytes": 0, "modified": "Fri, 25 Oct 2013 00:05:18 +0000", "path": "/home", "is_dir": true, "icon": "folder", "root": "dropbox", "size": "0 bytes"}, {"revision": 1, "rev": "114372dc4", "thumb_exists": false, "bytes": 1223, "modified": "Mon, 16 Sep 2013 21:00:23 +0000", "client_mtime": "Mon, 16 Sep 2013 21:00:23 +0000", "path": "/serial.c", "is_dir": false, "icon": "page_white_code", "root": "dropbox", "mime_type": "text/x-csrc", "size": "1.2 KB"}], "icon": "folder"}
- echo "$DIR_CONTENT" | sed 's/\"/\u0022/' | sed -n 's/.*"bytes": *([0-9]*),.*"path": *"([^"]*)",.*"is_dir": *([^"]*),.*/2:3;1/p'
- /home:true;0
- /serial.c:false;1223
- /home:true;0;Fri, 25 Oct 2013 00:05:18 +0000
- /serial.c:false;1223;Mon, 16 Sep 2013 21:00:23 +0000
- $ echo "$DIR_CONTENT" | sed 's/\"/\u0022/' | sed -n 's/.*"bytes": *([0-9]*),.*"modified": *"([^"]*).*"path": *"([^"]*)",.*"is_dir": *([^"]*),.*/3:4;1;2/p'
- /serial.c:false;1223;Mon, 16 Sep 2013 21:00:23 +0000
- echo "$DIR_CONTENT" | sed 's/\"/\u0022/' | sed -n 's/.*"bytes": *([0-9]*),.*"modified"([^"]*)",.*"path": *"([^"]*)",.*"is_dir": *([^"]*),.*/3:4;1;2/p'
- echo "$DIR_CONTENT" | sed -nr '
- s#.*"contents": [([^]]*)].*#1#
- :X
- h
- s#({[^}]*}).*#1#
- s#"([^"]*)": ("?[^"]*"?),#1a2n#g
- s#.*bytesa([^n]*).*modifieda([^n]*).*patha([^n]*).*is_dira([^n]*).*#3:4;1;2#
- s#"##gp
- g
- /({[^}]*}), (.*)/{ s##2#; bX }
- '
- /home:true;0;Fri, 25 Oct 2013 00:05:18 +0000
- /serial.c:false;1223;Mon, 16 Sep 2013 21:00:23 +0000
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement