ajohnsen@google.com
6949b04215
Use ino64_t on linux, to match the output of stat64.
...
BUG=
R=sgjesse@google.com
Review URL: https://codereview.chromium.org//87623002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@30658 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-26 07:41:44 +00:00
ajohnsen@google.com
7fef1ff77a
Add support for working with large files on unix systems, in dart:io.
...
BUG=
R=sgjesse@google.com
Review URL: https://codereview.chromium.org//63363010
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@30399 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-19 11:38:20 +00:00
ajohnsen@google.com
c3a9f33ef8
Fix directory-listing to return a future on cancel.
...
This also fixes an issue where we would leake FDs/HANDLEs if the listing was interrupted.
Add new pause-resume-cancel test of directory listing.
BUG=https://code.google.com/p/dart/issues/detail?id=10163
R=sgjesse@google.com
Review URL: https://codereview.chromium.org//45833003
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@29454 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-29 15:04:59 +00:00
whesse@google.com
3c0c99a3b9
Add Directory.systemTemp getter to replace createSystemTemp().
...
BUG=dartbug.com/12496
R=rnystrom@google.com , sgjesse@google.com
Review URL: https://codereview.chromium.org//25720002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@28215 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-03 12:55:30 +00:00
whesse@google.com
b221c702a3
dart:io | Add Directory.CreateSystemTemp(template) and change Directory.CreateTemp(template).
...
BUG=dartbug.com/12496
R=sgjesse@google.com
Review URL: https://codereview.chromium.org//25279003
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@28097 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-01 15:38:01 +00:00
iposva@google.com
7769854d0d
- Do NOT mix malloc/free and new/delete!
...
R=sgjesse@google.com , sigmund@google.com
Review URL: https://codereview.chromium.org//16929007
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@24145 260f80e4-7a28-3924-810f-c04153c831b5
2013-06-18 15:44:21 +00:00
ajohnsen@google.com
1b83d3b52e
Make Directory.list pull-based, making it possible to pause, resume and cancel directory listing.
...
BUG=https://code.google.com/p/dart/issues/detail?id=10163 ,
R=sgjesse@google.com
Review URL: https://codereview.chromium.org//16813006
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@24074 260f80e4-7a28-3924-810f-c04153c831b5
2013-06-17 07:27:19 +00:00
podivilov@google.com
38be0d45cf
Provide a POSIX-compliant implementation of Directory::Current.
...
R=sgjesse@google.com , whesse@google.com
Review URL: https://codereview.chromium.org//15719002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@23024 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-22 16:09:07 +00:00
sgjesse@google.com
2ef54d314a
Add the ability to change the working directory
...
Directory.current have been changed from a factory constructor to a
getter and setter. The getter returns a Direcotry object holding the
current working directory. The setter changes the current working
directory of the Dart process.
R=whesse@google.com
BUG=https://code.google.com/p/dart/issues/detail?id=6316 , https://code.google.com/p/dart/issues/detail?id=8893
Review URL: https://codereview.chromium.org//13896034
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22116 260f80e4-7a28-3924-810f-c04153c831b5
2013-04-29 12:43:53 +00:00
smok@google.com
ebbc2020a2
Put everything in runtime/bin into '::dart::bin' namespace.
...
Review URL: https://codereview.chromium.org//14341015
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22032 260f80e4-7a28-3924-810f-c04153c831b5
2013-04-25 14:22:30 +00:00
whesse@google.com
7c56d46086
dart:io | Ensure that Directory.list terminates even when symbolic links create loops in the file system.
...
BUG=
Review URL: https://codereview.chromium.org//13818010
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@21199 260f80e4-7a28-3924-810f-c04153c831b5
2013-04-10 13:07:08 +00:00
ajohnsen@google.com
1bae12223b
Fix recursive directory-deletion of top-level files/links.
...
BUG=
Review URL: https://codereview.chromium.org//13771010
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@21060 260f80e4-7a28-3924-810f-c04153c831b5
2013-04-08 11:30:33 +00:00
ajohnsen@google.com
e75df511a6
Change how File/Directory/Link .delete works.
...
Now:
- File.delete works iff path is File or Link.
- Directory.delete works iff path is Directory or Link.
- Link.delete works iff path Link.
This now matches .exists.
BUG=
Review URL: https://codereview.chromium.org//13654002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@21045 260f80e4-7a28-3924-810f-c04153c831b5
2013-04-08 07:44:18 +00:00
ajohnsen@google.com
578331c57e
Fix directory-listing, directory-deletion and file deletion, when links are involved.
...
BUG=https://code.google.com/p/dart/issues/detail?id=4928,https://code.google.com/p/dart/issues/detail?id=9278,https://code.google.com/p/dart/issues/detail?id=9504
Review URL: https://codereview.chromium.org//13578003
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@20929 260f80e4-7a28-3924-810f-c04153c831b5
2013-04-04 17:30:17 +00:00
whesse@google.com
d2ea504b60
dart:io | Add "followLinks" optional parameter to Directory.list, let it return Link objects when false.
...
BUG=dartbug.com/7720
Review URL: https://codereview.chromium.org//12638039
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@20370 260f80e4-7a28-3924-810f-c04153c831b5
2013-03-22 09:56:14 +00:00
iposva@google.com
9046a44a37
Prepare for removal of source_filter.gypi:
...
- Guard OS-dependent source files with #if TARGET_OS_* in a similar
fashion to the architecture dependent sources.
Review URL: https://codereview.chromium.org//12282051
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@18786 260f80e4-7a28-3924-810f-c04153c831b5
2013-02-20 21:17:38 +00:00
whesse@google.com
f15afd86b2
dart:io Directory.list: Fix use of snprintf return value to work with both C99, Windows, and pre-C99 versions of snprintf.
...
BUG=
Review URL: https://codereview.chromium.org//12326007
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@18754 260f80e4-7a28-3924-810f-c04153c831b5
2013-02-20 13:34:50 +00:00
whesse@google.com
25e5ba7f5f
Change Directory.list to use the input path, and not resolve it to a full path.
...
All paths reported by Directory.list are now extensions of the input path.
The Windows platform equivalent change will be committed in a separate CL.
BUG=
Review URL: https://codereview.chromium.org//12217086
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@18739 260f80e4-7a28-3924-810f-c04153c831b5
2013-02-20 09:27:08 +00:00
whesse@google.com
45e351e689
Add string.h header file to directory listing implementations.
...
BUG=
Review URL: https://codereview.chromium.org//12221086
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@18248 260f80e4-7a28-3924-810f-c04153c831b5
2013-02-08 12:21:56 +00:00
whesse@google.com
58e8b94008
Use a PathBuffer class in dart:io directory lister.
...
This simplifies the code, and avoids buffer overflow errors
by encapsulating snprintf.
BUG=
Review URL: https://codereview.chromium.org//12220034
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@18247 260f80e4-7a28-3924-810f-c04153c831b5
2013-02-08 11:58:12 +00:00
whesse@google.com
7f499abb04
Fix race condition in Directory.create.
...
BUG=https://code.google.com/p/dart/issues/detail?id=7679
Review URL: https://codereview.chromium.org//11794048
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@16842 260f80e4-7a28-3924-810f-c04153c831b5
2013-01-09 09:59:14 +00:00
ager@google.com
ccced31671
Change Directory.create to not fail on existing directory with that name.
...
The new semantics is to ensure that a directory with that name
exists. There is no way to reliably guard a create call against
existing directories in an async program.
R=sgjesse@google.com
BUG=
Review URL: https://codereview.chromium.org//11175054
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@13933 260f80e4-7a28-3924-810f-c04153c831b5
2012-10-23 09:15:01 +00:00
jackpal@google.com
e060b66a3e
Add _android files for building DartVM on Android
...
Split directory_posix -> directory_(android|linux|macos)
This allows us to cleanly make Android-specific changes to
directory_android.cc
Copy all _linux files to _android files and edit as needed to account
for the differences between Linux and Android:
+ getcwd(0, NULL) doesn't work on Android, have to emulate
+ Android doesn't have a '/tmp' directory, have to emulate
+ Android doesn't provide mkdtemp(), have to emulate.
+ Small differences in the available system include files.
+ Use pthread_cond_timedwait_monotonic instead of
pthread_condattr_setclock
Review URL: https://chromiumcodereview.appspot.com//10826233
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@10613 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-13 23:06:52 +00:00
ager@google.com
953d2599c1
Add exists, create and delete to directory implementation on Linux and Mac.
...
All of the directory implementations on Linux and Mac are identical
and uncontroversial. Join the implementations in directory_posix for
now. I will split it into the two files again if it becomes necessary.
BUG=
TEST=
Review URL: http://codereview.chromium.org//8277033
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@432 260f80e4-7a28-3924-810f-c04153c831b5
2011-10-14 12:42:44 +00:00
ager@google.com
c53c7097d0
Directory: implement recursive directory listing on Linux and Mac.
...
R=sgjesse@google.com
BUG=
TEST=
Review URL: http://codereview.chromium.org//8243005
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@363 260f80e4-7a28-3924-810f-c04153c831b5
2011-10-12 12:53:39 +00:00
ager@google.com
59135cc57b
Clean up directory listing interface.
...
Remove open and close. A directory instance just holds a string
representing the path to the directory.
R=sgjesse@google.com
BUG=
TEST=
Review URL: http://codereview.chromium.org//8244001
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@362 260f80e4-7a28-3924-810f-c04153c831b5
2011-10-12 10:39:30 +00:00
ager@google.com
023fa46e48
Finish non-recursive synchronous directory listing on Linux and Mac.
...
Next steps: Testing, Windows support and using isolates to make
listing async.
We should probably change the API to not tie a Directory object
to a given OS directory structure. When spawning an isolate to
perform a listing operation, that will open the directory,
list its contents and close the directory. That way we can
do multiple listing operations with the same Directory object
without having interference.
R=sgjesse@google.com ,iposva@google.com
BUG=
TEST=
Review URL: https://chromereviews.googleplex.com/3511020
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43 260f80e4-7a28-3924-810f-c04153c831b5
2011-10-05 14:33:49 +00:00
dgrove@google.com
4c0f559d23
Initial checkin.
...
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@15 260f80e4-7a28-3924-810f-c04153c831b5
2011-10-05 05:20:07 +00:00