Giter VIP home page Giter VIP logo

afcclient's Introduction

afcclient

A simple CLI interface to AFC via libimobiledevice.

Requirements

Updated listing output

The output is no longer fugly!

$ ./afcclient -r ls
d    27           864    Sep 24 13:00    .
d     2            64    Nov 14 17:09    .HFS+ Private Directory Data
f     1             0    Mar 14 05:25    .Trashes
d     2            64    Aug 29 00:14    .ba
f     1             0    Nov 03 15:03    .bootstrapped
f     1             0    Oct 02 19:38    .file
d     5           160    Jun 12 07:16    .fseventsd
d     2            64    Sep 29 20:28    .mb
f     1             0    Nov 03 15:03    .mount_rw
d   102          3264    Mar 08 18:31    Applications
d     8           340    May 27 00:25    Developer
d    26           832    Feb 28 12:24    Library
d     3            96    Sep 29 13:19    System
l     1            11    Sep 24 13:00    User -> /var/mobile
d    61          1952    Feb 28 12:22    bin
d     2            64    Oct 28 07:07    boot
d     2            64    Oct 02 19:38    cores
d     4          1707    Sep 24 13:00    dev
l     1            11    Mar 14 05:24    etc -> private/etc
d     2            64    Oct 28 07:07    lib
d     2            64    Oct 28 07:07    mnt
d     6           192    May 03 16:32    private
d    47          1504    Feb 03 00:55    sbin
l     1            15    Mar 14 05:25    tmp -> private/var/tmp
d    12           384    Nov 03 15:03    usr
l     1            11    Nov 14 17:20    var -> private/var

Building

$ make

Running

if you are using the included libraries for mac / windows you will need to copy them into the same location
as afcclient binary

Usage

Usage: afcclient [ra:u:vhlRc] command cmdargs...

  Options:
    -r, --root                 Use the afc2 server if jailbroken (ignored with -a)
    -a, --appid=<APP-ID>       Access bundle directory for app-id
    -u, --uuid=<UDID>          Specify the device udid
    -v, --verbose              Enable verbose debug messages
    -h, --help                 Display this help message
    -l, --list                 List devices
    -R, --recursive            List the specified folder recursively
    -c, --clean                Cleans out folder after exporting/cloning

  New commands:
    clone  [path] [localpath]  clone directory folder into a local folder. (requires path and localpath)\n"
    clone  [localpath]         clone Documents folder into a local folder. (requires appid)
    export [path] [localpath]  export a specific directory to a local one (not recursive)
    documents                  recursive plist formatted list of entire ~/Documents folder (requires appid)

  Where "command" and "cmdargs..." are as folows:

    devinfo                    dump device info from AFC server
    ls <dir> [dir2...]         list remote directory contents
    info <path> [path2...]     dump remote file information
    mkdir <path> [path2...]    create directory at path
    rm <path> [path2...]       remove directory at path
    rename <from> <to>         rename path 'from' to path 'to'
    link <target> <link>       create a hard-link from 'link' to 'target'
    symlink <target> <link>    create a symbolic-link from 'link' to 'target'
    cat <path>                 cat contents of <path> to stdout
    get <path> [localpath]     download a file (default: current dir)
    put <localpath> [path]     upload a file (default: remote top-level dir)

Known Issues / TODO

  • clean up the code

Author

Eric Monti - esmonti at gmail dot com

tweaked by Kevin Bradley to remove clang requirement, include built libs for mac and windows (32 bit only for windows) and added some improved recursive listing functionality with plist output.

License

MIT - See LICENSE.txt

afcclient's People

Contributors

emonti avatar lechium avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.