Skip to content

Commit 8863698

Browse files
author
Bruce Eckel
committed
More Changes to OnJava
1 parent cc07c4b commit 8863698

13 files changed

Lines changed: 35 additions & 28 deletions

File tree

Ant-Common.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@
7474
<target name="base">
7575
<javac includeantruntime="false"
7676
classpath="${java.class.path};${basedir};${basedir}/.."
77-
srcdir="${basedir}/../net/mindview/">
77+
srcdir="${basedir}/../com/mindviewinc/">
7878
<compilerarg value="-Xmaxerrs"/>
7979
<compilerarg value="10"/>
8080
</javac>

build.xml

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -20,29 +20,29 @@
2020
</condition>
2121

2222
<filelist id="buildfiles" dir="."
23-
files="object/build.xml
23+
files="objects/build.xml
2424
operators/build.xml
2525
control/build.xml
26-
initialization/build.xml
27-
access/build.xml
28-
net/build.xml
29-
reusing/build.xml
26+
housekeeping/build.xml
27+
hiding/build.xml
28+
com/build.xml
29+
reuse/build.xml
3030
polymorphism/build.xml
3131
interfaces/build.xml
3232
innerclasses/build.xml
33-
holding/build.xml
33+
containers/build.xml
3434
exceptions/build.xml
3535
strings/build.xml
3636
typeinfo/build.xml
3737
generics/build.xml
3838
arrays/build.xml
39-
containers/build.xml
39+
containersindepth/build.xml
4040
io/build.xml
4141
xml/build.xml
4242
enums/build.xml
4343
annotations/build.xml
4444
concurrency/build.xml
45-
gui/build.xml
45+
ui/build.xml
4646
swt/build.xml
4747
patterns/build.xml
4848
references/build.xml

tools/AttachResults.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
from betools import CmdLine, visitDir, ruler, head
1616

1717
maxlinewidth = 59
18-
examplePath = Path(r"C:\Users\Bruce\Dropbox\__Dreaming-in-Java\ExtractedExamples")
18+
examplePath = Path(r"C:\Users\Bruce\Dropbox\___OnJava\ExtractedExamples")
1919

2020

2121
class JavaMain:
@@ -258,7 +258,7 @@ def flense(word):
258258

259259
os.chdir(str(examplePath / ".."))
260260
spelldict = SortedSet()
261-
with codecs.open(str(Path("DreamingInJava.htm")),'r', encoding='utf-8', errors='ignore') as book:
261+
with codecs.open(str(Path("OnJava.htm")),'r', encoding='utf-8', errors='ignore') as book:
262262
soup = BeautifulSoup(book.read())
263263
for b in soup.find_all("b"):
264264
text = (" ".join(b.text.split())).strip()

tools/Examples.py

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#! py -3
22
"""
3-
Extract code examples from Dreaming in Java plain text file.
3+
Extract code examples from On Java plain text file.
44
Creates Ant build.xml file for each subdirectory.
55
"""
66
TODO = """
@@ -19,9 +19,9 @@
1919

2020
# Leave this alone, relative path necessary:
2121
destination = Path('.') / "ExtractedExamples"
22-
sourceText = Path('.') / "DreamingInJava.txt"
23-
github = Path(r'C:\Users\Bruce\Documents\GitHub\Dreaming-in-Java')
24-
examples = Path(r"C:\Users\Bruce\Dropbox\__Dreaming-in-Java\ExtractedExamples")
22+
sourceText = Path('.') / "OnJava.txt"
23+
github = Path(r'C:\Users\Bruce\Documents\GitHub\On-Java')
24+
examples = Path(r"C:\Users\Bruce\Dropbox\___OnJava\ExtractedExamples")
2525

2626
startBuild = """\
2727
<?xml version="1.0" ?>
@@ -149,7 +149,7 @@ def _copy_from_github(dir, name_or_pattern, trace=False):
149149
for args in [
150150
(".", "build.xml"),
151151
(".", "Ant-*.xml"),
152-
("gui", "*.gif"),
152+
("ui", "*.gif"),
153153
("network", "*.bat"),
154154
("network", "build.xml"),
155155
("remote", "*.bat"),
@@ -360,7 +360,7 @@ def createAntFiles():
360360

361361
@CmdLine("f")
362362
def findNonJavaFiles():
363-
"Find non-java files in DreamingInJava.txt"
363+
"Find non-java files in OnJava.txt"
364364
if not sourceText.exists():
365365
print("Cannot find", sourceText)
366366
sys.exit()
@@ -374,7 +374,7 @@ def findNonJavaFiles():
374374

375375
@CmdLine('e')
376376
def extractAndCreateBuildFiles():
377-
"Clean, then extract examples from DreamingInJava.txt, build ant files"
377+
"Clean, then extract examples from OnJava.txt, build ant files"
378378
clean()
379379
extractExamples()
380380
createAntFiles()

tools/Validate.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
from betools import CmdLine, visitDir, ruler, head
2020

2121
maxlinewidth = 60
22-
examplePath = Path(r"C:\Users\Bruce\Dropbox\__Dreaming-in-Java\ExtractedExamples")
22+
examplePath = Path(r"C:\Users\Bruce\Dropbox\___OnJava\ExtractedExamples")
2323

2424
maindef = re.compile("public\s+static\s+void\s+main")
2525

@@ -482,7 +482,7 @@ def createChecklist():
482482
import codecs
483483
os.chdir(str(examplePath / ".."))
484484

485-
with codecs.open(str(Path("DreamingInJava.htm")),'r', encoding='utf-8', errors='ignore') as book:
485+
with codecs.open(str(Path("OnJava.htm")),'r', encoding='utf-8', errors='ignore') as book:
486486
soup = BeautifulSoup(book.read())
487487
with Path("Checklist-generated.txt").open('wb') as checklist:
488488
for h1 in soup.find_all("h1"):

tools/a.bat

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
@echo off
2-
python C:\Users\Bruce\Dropbox\__Dreaming-in-Java\AttachResults.py %*
2+
python C:\Users\Bruce\Dropbox\___OnJava\AttachResults.py %*

tools/backup.bat

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,12 @@ cp(dest, idrive)
4545

4646
shortcut = Path(r"C:\Python34\Scripts")
4747
tools = ["Examples.py", "Validate.py", "AttachResults.py", "backup.bat", "go.bat", "update_git.py",
48-
shortcut / "a.bat", shortcut / "v.bat", shortcut / "e.bat", shortcut / "g.bat", shortcut / "home.bat"]
48+
shortcut / "a.bat",
49+
shortcut / "v.bat",
50+
shortcut / "e.bat",
51+
shortcut / "g.bat",
52+
shortcut / "p.bat",
53+
shortcut / "home.bat"]
4954

5055
print("\nCopying tools to Github")
5156
for tool in tools:

tools/e.bat

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
@echo off
2-
python C:\Users\Bruce\Dropbox\__Dreaming-in-Java\Examples.py %*
2+
python C:\Users\Bruce\Dropbox\___OnJava\Examples.py %*

tools/g.bat

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
@echo off
2-
python C:\Users\Bruce\Dropbox\__Dreaming-in-Java\update_git.py %*
2+
python C:\Users\Bruce\Dropbox\___OnJava\update_git.py %*

tools/home.bat

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
@echo off
2-
cd C:\Users\Bruce\Dropbox\__Dreaming-in-Java
2+
cd C:\Users\Bruce\Dropbox\___OnJava

0 commit comments

Comments
 (0)