-
Notifications
You must be signed in to change notification settings - Fork 72
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix issues #42 #43 #44 #45 and #47 #46
Changes from 22 commits
280a975
c06aff5
4359e51
85902f7
18acd5e
7b964c6
d8b589c
d5827b3
618fda8
6128ab3
92fdfd4
ce23f36
4752056
d7b7c2a
8e9cd33
8740b56
b1dc2a0
2dc62c2
ba89c3c
16e0c91
c7c1aba
b0fbabd
6a0f6dc
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,7 +9,7 @@ | |
|
||
<groupId>org.netpreserve.commons</groupId> | ||
<artifactId>webarchive-commons</artifactId> | ||
<version>1.1.6-SNAPSHOT</version> | ||
<version>1.1.7-SNAPSHOT</version> | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @anjackson should this still be 1.1.6? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yes, the last release was 1.1.5. |
||
<packaging>jar</packaging> | ||
|
||
<name>webarchive-commons</name> | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,7 @@ | ||
package org.archive.extract; | ||
|
||
import java.io.FileNotFoundException; | ||
import java.io.FileOutputStream; | ||
import java.io.IOException; | ||
import java.io.OutputStream; | ||
import java.io.OutputStreamWriter; | ||
|
@@ -74,7 +75,7 @@ public int run(String[] args) | |
if(args.length < 1) { | ||
return USAGE(1); | ||
} | ||
if(args.length > 3) { | ||
if(args.length > 4) { | ||
return USAGE(1); | ||
} | ||
int max = Integer.MAX_VALUE; | ||
|
@@ -89,7 +90,14 @@ public int run(String[] args) | |
} | ||
} | ||
String path = args[arg]; | ||
if(args.length == arg + 2) { | ||
String outputFile = null; | ||
if(args.length >= arg + 2) { | ||
//if a output file is specified in the command line | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. space after "//" |
||
if(args.length == arg + 3) { | ||
outputFile = args[arg+2]; | ||
os.close(); | ||
os = new FileOutputStream(outputFile); | ||
} | ||
if(args[arg].equals("-cdx")) { | ||
path = args[arg+1]; | ||
out = new RealCDXExtractorOutput(makePrintWriter(os)); | ||
|
@@ -100,7 +108,7 @@ public int run(String[] args) | |
|
||
} else if(args[arg].equals("-wat")) { | ||
path = args[arg+1]; | ||
out = new WATExtractorOutput(os); | ||
out = new WATExtractorOutput(os, outputFile); | ||
} else { | ||
String filter = args[arg+1]; | ||
out = new JSONViewExtractorOutput(os, filter); | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
operator= | ||
publisher= | ||
wat.warcinfo.description= | ||
warc.format=WARC File Format 1.0 | ||
warc.format.conforms.to=http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you add a line in here about the change you did for Entity-Trailing-Slop-Bytes should be called Entity-Trailing-Slop-Length (#48)? Thank you!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.