blob: b88ab5bfe86c7c3a38091ee9a6f28bb841280a72 [file] [log] [blame]
Mike Kleinadacaef2017-02-06 09:26:14 -05001/*
2 * Copyright 2017 Google Inc.
3 *
4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file.
6 */
7
8#import <Foundation/Foundation.h>
9#include "ios_utils.h"
10#include <unistd.h>
11
12void cd_Documents() {
13 @autoreleasepool {
14 NSURL* dir = [[[NSFileManager defaultManager]
15 URLsForDirectory:NSDocumentDirectory
16 inDomains:NSUserDomainMask] lastObject];
17 chdir([dir.path UTF8String]);
18 }
19}