@@ -77,16 +77,13 @@ class Commands {
7777 * @param {boolean } [options.cicero] whether to further transform for Cicero
7878 * @param {boolean } [options.slate] whether to further transform for Slate
7979 * @param {boolean } [options.html] whether to further transform for HTML
80- * @param {boolean } [options.noWrap] whether to avoid wrapping Cicero variables in XML tags
81- * @param {boolean } [options.noIndex] do not index ordered list (i.e., use 1. everywhere)
8280 * @param {boolean } [options.verbose] verbose output
8381 * @returns {object } Promise to the result of parsing
8482 */
8583 static parse ( samplePath , outputPath , options ) {
86- const { cicero, slate, html, noWrap , noIndex , verbose } = options ;
84+ const { cicero, slate, html, verbose } = options ;
8785 const commonOptions = { } ;
8886 commonOptions . tagInfo = true ;
89- commonOptions . noIndex = noIndex ? true : false ;
9087
9188 const commonMark = new CommonMarkTransformer ( commonOptions ) ;
9289 const ciceroMark = new CiceroMarkTransformer ( ) ;
@@ -166,15 +163,14 @@ class Commands {
166163 * @returns {object } Promise to the result of parsing
167164 */
168165 static draft ( dataPath , outputPath , options ) {
169- const { roundtrip , cicero, slate, html , noWrap, noIndex, verbose } = options ;
166+ const { cicero, slate, noWrap, noIndex, verbose } = options ;
170167 const commonOptions = { } ;
171168 commonOptions . tagInfo = true ;
172169 commonOptions . noIndex = noIndex ? true : false ;
173170
174171 const commonMark = new CommonMarkTransformer ( commonOptions ) ;
175172 const ciceroMark = new CiceroMarkTransformer ( ) ;
176173 const slateMark = new SlateTransformer ( ) ;
177- const htmlMark = new HtmlTransformer ( ) ;
178174
179175 let result = JSON . parse ( Fs . readFileSync ( dataPath , 'utf8' ) ) ;
180176 if ( cicero ) {
@@ -198,8 +194,6 @@ class Commands {
198194 Logger . info ( '=== CommonMark ===' ) ;
199195 Logger . info ( JSON . stringify ( result , null , 4 ) ) ;
200196 }
201- } else if ( html ) {
202- throw new Error ( 'Cannot roundtrip from HTML' ) ;
203197 }
204198 result = commonMark . toMarkdown ( result ) ;
205199 if ( outputPath ) {
@@ -239,15 +233,14 @@ class Commands {
239233 * @returns {object } Promise to the result of parsing
240234 */
241235 static normalize ( samplePath , outputPath , options ) {
242- const { roundtrip , cicero, slate, html , noWrap, noIndex, verbose } = options ;
236+ const { cicero, slate, noWrap, noIndex, verbose } = options ;
243237 const commonOptions = { } ;
244238 commonOptions . tagInfo = true ;
245239 commonOptions . noIndex = noIndex ? true : false ;
246240
247241 const commonMark = new CommonMarkTransformer ( commonOptions ) ;
248242 const ciceroMark = new CiceroMarkTransformer ( ) ;
249243 const slateMark = new SlateTransformer ( ) ;
250- const htmlMark = new HtmlTransformer ( ) ;
251244
252245 const markdownText = Fs . readFileSync ( samplePath , 'utf8' ) ;
253246 let result = commonMark . fromMarkdown ( markdownText , 'json' ) ;
@@ -297,8 +290,6 @@ class Commands {
297290 Logger . info ( '=== CommonMark ===' ) ;
298291 Logger . info ( JSON . stringify ( result , null , 4 ) ) ;
299292 }
300- } else if ( html ) {
301- throw new Error ( 'Cannot roundtrip from HTML' ) ;
302293 }
303294 result = commonMark . toMarkdown ( result ) ;
304295 if ( outputPath ) {
0 commit comments