iOS 获取当前用户的用户路径并写入文件

        NSString *path = [[@"~" stringByExpandingTildeInPath] stringByAppendingString: @"/tmp.txt"];
        [path writeToFile:path atomically:YES encoding:NSUTF8StringEncoding error:nil];

  

posted @ 2015-12-12 10:02  Ficow  阅读(390)  评论(0编辑  收藏  举报