Last change
on this file since 31525 was 31525, checked in by ak19, 7 years ago |
Nathan provided more stuff: Themes folder contains Sencha's Themebuilder which generates GXT Themes. It includes the .theme and generated .jar files for the project theme.
|
File size:
462 bytes
|
Line | |
---|
1 | # List all the files in a Tree of Directories
|
---|
2 | system = require 'system'
|
---|
3 |
|
---|
4 | if system.args.length != 2
|
---|
5 | console.log "Usage: phantomjs scandir.coffee DIRECTORY_TO_SCAN"
|
---|
6 | phantom.exit 1
|
---|
7 | scanDirectory = (path) ->
|
---|
8 | fs = require 'fs'
|
---|
9 | if fs.exists(path) and fs.isFile(path)
|
---|
10 | console.log path
|
---|
11 | else if fs.isDirectory(path)
|
---|
12 | fs.list(path).forEach (e) ->
|
---|
13 | scanDirectory path + "/" + e if e != "." and e != ".."
|
---|
14 |
|
---|
15 | scanDirectory system.args[1]
|
---|
16 | phantom.exit()
|
---|
Note:
See
TracBrowser
for help on using the repository browser.