Skip to content

Commit 3026f19

Browse files
committed
Convention for --
1 parent 32dd573 commit 3026f19

File tree

5 files changed

+21
-21
lines changed

5 files changed

+21
-21
lines changed

tastydoc/readme.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@ This tool produces Markdown documentation files for Scala projects using TASTy f
44

55
## How to run
66
Call main with the following arguments to produce Markdown documentation files: (Omitting { and })
7-
* **-syntax** {*wiki or markdown*} Syntax for parsing user documentation
8-
* **-packagestolink** {*regex1 regex2 ...*} Regexes to specify which packages should be linked when formatting Reference
9-
* **-classpath** {*URI*} Extra classpath for input files
7+
* **--syntax** {*wiki or markdown*} Syntax for parsing user documentation
8+
* **--packagestolink** {*regex1 regex2 ...*} Regexes to specify which packages should be linked when formatting Reference
9+
* **--classpath** {*URI*} Extra classpath for input files
1010
* **-i** {*file1 file2 ...*} TASTy files
1111
* **-d** {*dir1 dir2 ...*} Directories to recursively find TASTy files

tastydoc/report/report.pdf

80 Bytes
Binary file not shown.

tastydoc/report/report.tex

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -183,9 +183,9 @@ \subsection{Main}
183183

184184
Command line arguments are:
185185
\begin{itemize}
186-
\item \textbf{-syntax} \{\textit{wiki} or \textit{markdown}\} Syntax to use for user documentation parsing
187-
\item \textbf{-packagestolink} \{\textit{regex1 regex2 ...}\} Regexes to specify which packages should be linked when formatting References
188-
\item \textbf{-classpath} \{\textit{URI}\} Extra classpath for input files
186+
\item \textbf{--syntax} \{\textit{wiki} or \textit{markdown}\} Syntax to use for user documentation parsing
187+
\item \textbf{--packagestolink} \{\textit{regex1 regex2 ...}\} Regexes to specify which packages should be linked when formatting References
188+
\item \textbf{--classpath} \{\textit{URI}\} Extra classpath for input files
189189
\item \textbf{-i} \{\textit{file1 file2 ...}\} TASTy files
190190
\item \textbf{-d} \{\textit{dir1 dir2 ...}\} Directories to recursively find TASTy files
191191
\end{itemize}

tastydoc/src/dotty/tastydoc/Main.scala

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,15 +10,15 @@ import java.io._
1010
object Main {
1111

1212
/** Call main with the following arguments to produce Markdown documentation files: (Omitting { and })
13-
* * **-syntax** {*wiki or markdown*} Syntax for parsing user documentation
14-
* * **-packagestolink** {*regex1 regex2 ...*} Regexes to specify which packages should be linked when formatting Reference
15-
* * **-classpath** {*URI*} Extra classpath for input files
13+
* * **--syntax** {*wiki or markdown*} Syntax for parsing user documentation
14+
* * **--packagestolink** {*regex1 regex2 ...*} Regexes to specify which packages should be linked when formatting Reference
15+
* * **--classpath** {*URI*} Extra classpath for input files
1616
* * **-i** {*file1 file2 ...*} TASTy files
1717
* * **-d** {*dir1 dir2 ...*} Directories to recursively find TASTy files
1818
*/
1919
def main(args: Array[String]): Unit = {
2020
val userDocSyntax = {
21-
val idx = args.indexOf("-syntax")
21+
val idx = args.indexOf("--syntax")
2222
if(idx >= 0 && args.size > idx + 1){
2323
if(args(idx + 1) == "markdown"){
2424
"markdown"
@@ -34,7 +34,7 @@ object Main {
3434
}
3535

3636
val packagesToLink = {
37-
val idx = args.indexOf("-packagestolink")
37+
val idx = args.indexOf("--packagestolink")
3838
if(idx >= 0 && args.size > idx + 1){
3939
args.drop(idx + 1).takeWhile(! _.startsWith("-")).toList
4040
}else{
@@ -44,7 +44,7 @@ object Main {
4444

4545

4646
val extraClasspath = {
47-
val idx = args.indexOf("-classpath")
47+
val idx = args.indexOf("--classpath")
4848
if(idx >= 0 && args.size > idx + 1){
4949
args(idx + 1)
5050
}else{

tastydoc/test/dotty/tastydoc/Tests.scala

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -51,12 +51,12 @@ class Tests {
5151
// }
5252
@Test def testDocumentation(): Unit = {
5353
Main.main(Array(
54-
"-classpath",
54+
"--classpath",
5555
"tastydoc/out/bootstrap/dotty-tastydoc-input/scala-0.16/classes",
56-
"-syntax",
56+
"--syntax",
5757
"wiki",
5858
//"markdown",
59-
"-packagestolink",
59+
"--packagestolink",
6060
"example.*",
6161
//"scala.*",
6262
"-i",
@@ -73,23 +73,23 @@ class Tests {
7373
}
7474
@Test def testListFromLib(): Unit = {
7575
Main.main(Array(
76-
"-classpath",
76+
"--classpath",
7777
"tastydoc/out/bootstrap/dotty-tastydoc-input/scala-0.16/classes",
78-
"-syntax",
78+
"--syntax",
7979
"wiki",
80-
"-packagestolink",
80+
"--packagestolink",
8181
"scala.*",
8282
"-i",
8383
"scala.collection.immutable.List"
8484
))
8585
}
8686
// @Test def testDotty(): Unit = {
8787
// Main.main(Array(
88-
// "-classpath",
88+
// "--classpath",
8989
// "tastydoc/dotty-0.15.0-RC1/lib",
90-
// "-syntax",
90+
// "--syntax",
9191
// "wiki",
92-
// "-packagestolink",
92+
// "--packagestolink",
9393
// "dotty.*",
9494
// "scala.internal.*",
9595
// "scala.annotation.*",

0 commit comments

Comments
 (0)