You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@karaf.apache.org by jb...@apache.org on 2013/05/06 16:31:00 UTC
svn commit: r1479580 - in /karaf/branches/karaf-2.3.x/shell/commands/src:
main/java/org/apache/karaf/shell/commands/
main/resources/META-INF/services/org/apache/karaf/shell/
main/resources/OSGI-INF/ main/resources/OSGI-INF/blueprint/
main/resources/org...
Author: jbonofre
Date: Mon May 6 14:30:59 2013
New Revision: 1479580
URL: http://svn.apache.org/r1479580
Log:
[KARAF-2164] Create wc command
Added:
karaf/branches/karaf-2.3.x/shell/commands/src/main/java/org/apache/karaf/shell/commands/WcAction.java
karaf/branches/karaf-2.3.x/shell/commands/src/main/resources/org/apache/karaf/shell/commands/wc.txt
karaf/branches/karaf-2.3.x/shell/commands/src/test/java/org/apache/karaf/shell/commands/WcTest.java
karaf/branches/karaf-2.3.x/shell/commands/src/test/resources/
karaf/branches/karaf-2.3.x/shell/commands/src/test/resources/org/
karaf/branches/karaf-2.3.x/shell/commands/src/test/resources/org/apache/
karaf/branches/karaf-2.3.x/shell/commands/src/test/resources/org/apache/karaf/
karaf/branches/karaf-2.3.x/shell/commands/src/test/resources/org/apache/karaf/shell/
karaf/branches/karaf-2.3.x/shell/commands/src/test/resources/org/apache/karaf/shell/commands/
karaf/branches/karaf-2.3.x/shell/commands/src/test/resources/org/apache/karaf/shell/commands/WcActionTestLarge.txt
karaf/branches/karaf-2.3.x/shell/commands/src/test/resources/org/apache/karaf/shell/commands/WcActionTestSmall.txt
Modified:
karaf/branches/karaf-2.3.x/shell/commands/src/main/resources/META-INF/services/org/apache/karaf/shell/commands
karaf/branches/karaf-2.3.x/shell/commands/src/main/resources/OSGI-INF/blueprint/shell-commands.xml
karaf/branches/karaf-2.3.x/shell/commands/src/main/resources/OSGI-INF/bundle.info
Added: karaf/branches/karaf-2.3.x/shell/commands/src/main/java/org/apache/karaf/shell/commands/WcAction.java
URL: http://svn.apache.org/viewvc/karaf/branches/karaf-2.3.x/shell/commands/src/main/java/org/apache/karaf/shell/commands/WcAction.java?rev=1479580&view=auto
==============================================================================
--- karaf/branches/karaf-2.3.x/shell/commands/src/main/java/org/apache/karaf/shell/commands/WcAction.java (added)
+++ karaf/branches/karaf-2.3.x/shell/commands/src/main/java/org/apache/karaf/shell/commands/WcAction.java Mon May 6 14:30:59 2013
@@ -0,0 +1,215 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.karaf.shell.commands;
+
+import org.apache.felix.gogo.commands.Argument;
+import org.apache.felix.gogo.commands.Command;
+import org.apache.felix.gogo.commands.Option;
+import org.apache.karaf.shell.console.AbstractAction;
+
+import java.io.*;
+import java.util.List;
+
+@Command(scope = "shell", name = "wc", description = "Print newline, word, and byte counts for each file.")
+public class WcAction extends AbstractAction {
+
+ @Option(name = "-l", aliases = { "--lines" }, description = "Print the newline counts.", required = false, multiValued = false)
+ private boolean lines;
+
+ @Option(name = "-w", aliases = { "--words" }, description = "Print the word counts.", required = false, multiValued = false)
+ private boolean words;
+
+ @Option(name = "-m", aliases = { "--chars" }, description = "Print the character counts.", required = false, multiValued = false)
+ private boolean chars;
+
+ @Option(name = "-c", aliases = { "--bytes" }, description = "Print the byte counts.", required = false, multiValued = false)
+ private boolean bytes;
+
+ @Argument(index = 0, name = "files", description = "The list of files where to perform the count.", required = false, multiValued = true)
+ private List<File> files;
+
+ @Override
+ protected Object doExecute() throws Exception {
+ setDefaultOptions();
+
+ String resultString;
+
+ if (files == null) {
+ WordCounts wordCounts = getWordCounts(System.in);
+ resultString = formatWordCounts(wordCounts, null);
+ } else {
+ resultString = getFilesWordCounts(files);
+ }
+
+ System.out.println(resultString);
+
+ return null;
+ }
+
+ protected void setDefaultOptions() {
+ boolean noOptionSupplied = !(lines || words || chars || bytes);
+
+ if (noOptionSupplied) {
+ lines = true;
+ words = true;
+ bytes = true;
+ }
+ }
+
+ /**
+ * Create a combined word count for the given files.
+ * if there are more than one file supplied, a total row will be added.
+ *
+ * @param files the files to word count.
+ * @return the word count result.
+ * @throws IOException in case of counting failure.
+ */
+ protected String getFilesWordCounts(List<File> files) throws IOException {
+ StringBuilder stringBuilder = new StringBuilder();
+ WordCounts totalWordCounts = new WordCounts();
+ for (File file : files) {
+ WordCounts fileWordCounts = getWordCounts(new FileInputStream(file));
+ String fileResultString = formatWordCounts(fileWordCounts, file.getName());
+
+ totalWordCounts = totalWordCounts.add(fileWordCounts);
+ stringBuilder.append(fileResultString).append('\n');
+ }
+ // add an additional total row
+ if (files.size() > 1) {
+ stringBuilder.append(formatWordCounts(totalWordCounts, "total"));
+ }
+
+ return stringBuilder.toString();
+ }
+
+ /**
+ * Perform the main logic of counting the relevant data within a given input stream.
+ * <p/>
+ * Note, a line is considered to be terminated by linefeed '\n' or carriage return '\r'
+ * a previous linefeed will be consumed.
+ * <p/>
+ * This method assumed UTF-8.
+ *
+ * @param inputStream the input stream where to count.
+ * @return the word counts.
+ * @throws IOException in case of counting failure.
+ */
+ protected WordCounts getWordCounts(InputStream inputStream) throws IOException {
+ WordCounts wordCounts = new WordCounts();
+
+ BufferedReader bufferedReader = null;
+ try {
+ bufferedReader = new BufferedReader(new InputStreamReader(inputStream));
+
+ int current;
+ boolean skipNextLineFeed = false;
+ boolean previousWhitespace = true;
+ while ((current = bufferedReader.read()) != -1) {
+
+ wordCounts.byteCount++;
+ wordCounts.charCount++;
+
+ // line handling
+ // if a previous new line has been read, the next newline feed should be skipped
+ boolean isSkipNewLineFeed = skipNextLineFeed && current == '\n';
+ skipNextLineFeed = false;
+ if (isSkipNewLineFeed) {
+ continue;
+ }
+
+ boolean eol = (current == '\n' || current == '\r');
+ if (eol) {
+ wordCounts.lineCount++;
+ // store the state to skip the next linefeed if required
+ if (current == '\r') {
+ skipNextLineFeed = true;
+ }
+ }
+
+ // word handling
+ boolean isCurrentWhitespace = Character.isWhitespace(current);
+ if (!isCurrentWhitespace && previousWhitespace) {
+ wordCounts.wordCount++;
+ }
+ previousWhitespace = isCurrentWhitespace;
+ }
+ } finally {
+ if (bufferedReader != null) {
+ bufferedReader.close();
+ }
+ }
+
+ return wordCounts;
+ }
+
+ /**
+ * Create a human readable String of the given count information.
+ *
+ * @param wordCounts the word counts containing the different counts data.
+ * @param reportName the name associated with the word counts, ie a file name.
+ * @return the human readable String.
+ */
+ protected String formatWordCounts(WordCounts wordCounts, String reportName) {
+ StringBuilder stringBuilder = new StringBuilder();
+
+ if (lines) {
+ stringBuilder.append('\t').append(wordCounts.lineCount);
+ }
+
+ if (words) {
+ stringBuilder.append('\t').append(wordCounts.wordCount);
+ }
+
+ if (chars) {
+ stringBuilder.append('\t').append(wordCounts.charCount);
+ }
+
+ if (bytes) {
+ stringBuilder.append('\t').append(wordCounts.byteCount);
+ }
+
+ if (reportName != null) {
+ stringBuilder.append('\t').append(reportName);
+ }
+
+ return stringBuilder.toString();
+ }
+
+ /**
+ * Represent a basic object which stores the relevant counts information.
+ */
+ protected static class WordCounts {
+
+ protected int lineCount;
+ protected int wordCount;
+ protected int byteCount;
+ protected int charCount;
+
+ public WordCounts add(WordCounts append) {
+ WordCounts result = new WordCounts();
+ result.lineCount = lineCount + append.lineCount;
+ result.wordCount = wordCount + append.wordCount;
+ result.byteCount = byteCount + append.byteCount;
+ result.charCount = charCount + append.charCount;
+ return result;
+ }
+
+ }
+
+}
Modified: karaf/branches/karaf-2.3.x/shell/commands/src/main/resources/META-INF/services/org/apache/karaf/shell/commands
URL: http://svn.apache.org/viewvc/karaf/branches/karaf-2.3.x/shell/commands/src/main/resources/META-INF/services/org/apache/karaf/shell/commands?rev=1479580&r1=1479579&r2=1479580&view=diff
==============================================================================
--- karaf/branches/karaf-2.3.x/shell/commands/src/main/resources/META-INF/services/org/apache/karaf/shell/commands (original)
+++ karaf/branches/karaf-2.3.x/shell/commands/src/main/resources/META-INF/services/org/apache/karaf/shell/commands Mon May 6 14:30:59 2013
@@ -33,3 +33,4 @@ org.apache.karaf.shell.commands.SleepAct
org.apache.karaf.shell.commands.SortAction
org.apache.karaf.shell.commands.TacAction
org.apache.karaf.shell.commands.TailAction
+org.apache.karaf.shell.commands.WcAction
\ No newline at end of file
Modified: karaf/branches/karaf-2.3.x/shell/commands/src/main/resources/OSGI-INF/blueprint/shell-commands.xml
URL: http://svn.apache.org/viewvc/karaf/branches/karaf-2.3.x/shell/commands/src/main/resources/OSGI-INF/blueprint/shell-commands.xml?rev=1479580&r1=1479579&r2=1479580&view=diff
==============================================================================
--- karaf/branches/karaf-2.3.x/shell/commands/src/main/resources/OSGI-INF/blueprint/shell-commands.xml (original)
+++ karaf/branches/karaf-2.3.x/shell/commands/src/main/resources/OSGI-INF/blueprint/shell-commands.xml Mon May 6 14:30:59 2013
@@ -94,6 +94,9 @@
<null/>
</completers>
</command>
+ <command name="shell/wc">
+ <action class="org.apache.karaf.shell.commands.WcAction"/>
+ </command>
</command-bundle>
<bean id="commandCompleter" class="org.apache.karaf.shell.console.completer.CommandsCompleter"/>
Modified: karaf/branches/karaf-2.3.x/shell/commands/src/main/resources/OSGI-INF/bundle.info
URL: http://svn.apache.org/viewvc/karaf/branches/karaf-2.3.x/shell/commands/src/main/resources/OSGI-INF/bundle.info?rev=1479580&r1=1479579&r2=1479580&view=diff
==============================================================================
--- karaf/branches/karaf-2.3.x/shell/commands/src/main/resources/OSGI-INF/bundle.info (original)
+++ karaf/branches/karaf-2.3.x/shell/commands/src/main/resources/OSGI-INF/bundle.info Mon May 6 14:30:59 2013
@@ -30,6 +30,7 @@
\u001B[36mshell:sort\u001B[0m Writes sorted concatenation of all files to standard output.
\u001B[36mshell:tac\u001B[0m Captures the STDIN and returns it as a string. Optionally writes the content to a file.
\u001B[36mshell:tail\u001B[0m Displays the last lines of a file.
+ \u001B[36mshell:wc\u001B[0m Performs counting operations on Strings/files.
\u001B[1mSEE ALSO\u001B[0m
\u001B[36mCommands\u001B[0m and \u001B[36mUsing the console\u001B[0m sections of the Karaf User Guide.
\ No newline at end of file
Added: karaf/branches/karaf-2.3.x/shell/commands/src/main/resources/org/apache/karaf/shell/commands/wc.txt
URL: http://svn.apache.org/viewvc/karaf/branches/karaf-2.3.x/shell/commands/src/main/resources/org/apache/karaf/shell/commands/wc.txt?rev=1479580&view=auto
==============================================================================
--- karaf/branches/karaf-2.3.x/shell/commands/src/main/resources/org/apache/karaf/shell/commands/wc.txt (added)
+++ karaf/branches/karaf-2.3.x/shell/commands/src/main/resources/org/apache/karaf/shell/commands/wc.txt Mon May 6 14:30:59 2013
@@ -0,0 +1,35 @@
+This command will output the information in the following format
+
+ Lines Words Characters Bytes Name
+
+Note, the name field will not always be present. For example, in the case of a piped
+application of wc.
+
+Example usage :
+
+ Display information about a single file
+
+ wc LICENSE
+
+ Which outputs
+
+ 475 4053 28230 LICENSE
+
+ Display information about multiple files
+
+ wc LICENSE README RELEASE-NOTES
+
+ Which outputs
+
+ 475 4053 28230 LICENSE
+ 77 562 3933 README
+ 1831 16765 118449 RELEASE-NOTES
+ 2383 21380 150612 total
+
+ Piped example
+
+ echo "Hello World" | wc -w -l
+
+ Which outputs
+
+ 1 2
\ No newline at end of file
Added: karaf/branches/karaf-2.3.x/shell/commands/src/test/java/org/apache/karaf/shell/commands/WcTest.java
URL: http://svn.apache.org/viewvc/karaf/branches/karaf-2.3.x/shell/commands/src/test/java/org/apache/karaf/shell/commands/WcTest.java?rev=1479580&view=auto
==============================================================================
--- karaf/branches/karaf-2.3.x/shell/commands/src/test/java/org/apache/karaf/shell/commands/WcTest.java (added)
+++ karaf/branches/karaf-2.3.x/shell/commands/src/test/java/org/apache/karaf/shell/commands/WcTest.java Mon May 6 14:30:59 2013
@@ -0,0 +1,113 @@
+/*
+* Licensed to the Apache Software Foundation (ASF) under one
+* or more contributor license agreements. See the NOTICE file
+* distributed with this work for additional information
+* regarding copyright ownership. The ASF licenses this file
+* to you under the Apache License, Version 2.0 (the
+* "License"); you may not use this file except in compliance
+* with the License. You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing,
+* software distributed under the License is distributed on an
+* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+* KIND, either express or implied. See the License for the
+* specific language governing permissions and limitations
+* under the License.
+*/
+package org.apache.karaf.shell.commands;
+
+import junit.framework.TestCase;
+
+import java.io.ByteArrayInputStream;
+import java.io.File;
+import java.io.InputStream;
+import java.util.Arrays;
+import java.util.List;
+
+public class WcTest extends TestCase {
+
+ private static final String SMALL_FILE = "WcActionTestSmall.txt";
+ private static final String LARGE_FILE = "WcActionTestLarge.txt";
+
+ public void testEmptyStringWordCounts() throws Exception {
+ String string = "";
+ WcAction.WordCounts expected = new WcAction.WordCounts();
+ WcAction.WordCounts actual = getWordCounts(string);
+ assertEquals(expected, actual);
+ }
+
+ public void testHelloWorldWordCounts() throws Exception {
+ String string = "Hello World";
+ WcAction.WordCounts expected = new WcAction.WordCounts();
+ expected.wordCount = 2;
+ expected.lineCount = 0;
+ expected.charCount = 11;
+ expected.byteCount = 11;
+ WcAction.WordCounts actual = getWordCounts(string);
+ assertEquals(expected, actual);
+ }
+
+ public void testLargeStringWordCounts() throws Exception {
+ InputStream stream = WcTest.class.getResourceAsStream(LARGE_FILE);
+
+ WcAction.WordCounts expected = new WcAction.WordCounts();
+ expected.wordCount = 487;
+ expected.lineCount = 34;
+ expected.charCount = 3307;
+ expected.byteCount = 3307;
+
+ WcAction.WordCounts actual = getWordCounts(stream);
+ assertEquals(expected, actual);
+ }
+
+ public void testOneFileWordCounts() throws Exception {
+ File file = new File(WcTest.class.getResource(LARGE_FILE).toURI());
+ List<File> files = Arrays.asList(file);
+
+ WcAction wcAction = new WcAction();
+ wcAction.setDefaultOptions();
+
+ String result = wcAction.getFilesWordCounts(files);
+
+ assertEquals("A single file report should not contain a total count row", "\t34\t487\t3307\tWcActionTestLarge.txt\n", result);
+ }
+
+ public void testThreeFilesWordCounts() throws Exception {
+ File smallFile = new File(WcTest.class.getResource(SMALL_FILE).toURI());
+ File largeFile = new File(WcTest.class.getResource(LARGE_FILE).toURI());
+
+ List<File> files = Arrays.asList(smallFile, largeFile, smallFile);
+
+ WcAction wcAction = new WcAction();
+ wcAction.setDefaultOptions();
+
+ String result = wcAction.getFilesWordCounts(files);
+
+ assertEquals("A single file report should not contain a total",
+ "\t11\t12\t34\tWcActionTestSmall.txt\n" +
+ "\t34\t487\t3307\tWcActionTestLarge.txt\n" +
+ "\t11\t12\t34\tWcActionTestSmall.txt\n" +
+ "\t56\t511\t3375\ttotal"
+ , result);
+ }
+
+ public WcAction.WordCounts getWordCounts(String string) throws Exception {
+ InputStream inputStream = new ByteArrayInputStream(string.getBytes());
+ return getWordCounts(inputStream);
+ }
+
+ public WcAction.WordCounts getWordCounts(InputStream inputStream) throws Exception {
+ WcAction wcAction = new WcAction();
+ return wcAction.getWordCounts(inputStream);
+ }
+
+ public void assertEquals(WcAction.WordCounts expected, WcAction.WordCounts actual) {
+ assertEquals("The expected wordCount should be equal", expected.wordCount, actual.wordCount);
+ assertEquals("The expected lineCount should be equal", expected.lineCount, actual.lineCount);
+ assertEquals("The expected charCount should be equal", expected.charCount, actual.charCount);
+ assertEquals("The expected byteCount should be equal", expected.byteCount, actual.byteCount);
+ }
+
+}
Added: karaf/branches/karaf-2.3.x/shell/commands/src/test/resources/org/apache/karaf/shell/commands/WcActionTestLarge.txt
URL: http://svn.apache.org/viewvc/karaf/branches/karaf-2.3.x/shell/commands/src/test/resources/org/apache/karaf/shell/commands/WcActionTestLarge.txt?rev=1479580&view=auto
==============================================================================
--- karaf/branches/karaf-2.3.x/shell/commands/src/test/resources/org/apache/karaf/shell/commands/WcActionTestLarge.txt (added)
+++ karaf/branches/karaf-2.3.x/shell/commands/src/test/resources/org/apache/karaf/shell/commands/WcActionTestLarge.txt Mon May 6 14:30:59 2013
@@ -0,0 +1,35 @@
+Vestibulum egestas pulvinar lacus in congue. Phasellus nunc magna, sodales eu vestibulum eget, accumsan eu nisi.
+Nulla hendrerit mattis vehicula. Nullam lacinia metus in nulla convallis bibendum. Quisque vel tortor sit amet erat
+faucibus porta. Aliquam ac dui dui. Proin feugiat cursus dolor ut hendrerit. Curabitur quis odio et quam rutrum tincidunt.
+Quisque dignissim, elit et laoreet cursus, diam enim consectetur elit, eu tincidunt quam metus et nulla. Nam facilisis
+molestie interdum. Nunc adipiscing laoreet pretium. Donec pretium neque a dolor ornare adipiscing. Vestibulum ante ipsum
+primis in faucibus orci luctus et ultrices posuere cubilia Curae; Donec lacinia dictum risus, vitae ultrices lectus
+vehicula ac.
+
+Aenean id sodales lorem. Praesent malesuada elit ut urna elementum at egestas erat interdum. Cum sociis natoque penatibus
+et magnis dis parturient montes, nascetur ridiculus mus. Mauris egestas tempor elit, eget pretium est auctor at. Fusce
+vitae libero et leo facilisis tincidunt nec non libero. Pellentesque habitant morbi tristique senectus et netus et
+malesuada fames ac turpis egestas. Cras blandit mi vel enim vulputate in bibendum diam lacinia. Aliquam suscipit tempus
+ullamcorper. Proin viverra leo eget lacus elementum convallis vitae a tortor. Nullam vel ultricies magna. Aliquam
+laoreet odio sit amet velit rutrum pulvinar. Integer vel justo ipsum. Class aptent taciti sociosqu ad litora torquent
+per conubia nostra, per inceptos himenaeos. Vivamus vel odio quam, a vestibulum eros. Praesent augue purus, facilisis
+id commodo ut, suscipit sed sapien. Donec mollis, lectus nec fringilla dignissim, justo mauris sodales nisl, atpretium
+enim est ac nunc.
+
+Maecenas non nisl justo. Fusce interdum lorem in sem rhoncus consequat mattis vitae dolor. Donec mollis erat ac mi
+porttitor sagittis feugiat turpis porttitor. Ut in nulla id enim posuere hendrerit non mollis purus. Donec sit amet
+tellus nunc. Aenean in leo non sem vehicula euismod. Praesent porta feugiat leo non adipiscing. Sed neque arcu, laoreet
+a congue scelerisque, bibendum sit amet quam. Morbi fermentum iaculis justo, ac ullamcorper nisl varius vitae. Aenean
+aliquam egestas tellus, id dignissim magna interdum id.
+
+Suspendisse urna dolor, vehicula ac vulputate sed, gravida sed tortor. Nulla malesuada ipsum orci, nec pharetra est.
+Etiam vestibulum vulputate orci, sit amet pellentesque neque mattis vel. Suspendisse imperdiet, nisl eu consectetur
+luctus, velit magna adipiscing metus, aliquam dictum enim enim non tortor. Vestibulum ante ipsum primis in faucibus
+orci luctus et ultrices posuere cubilia Curae; Fusce in est eu elit dictum euismod non porta ipsum. Morbi mollis
+vestibulum mattis. Cras eu sapien eros. Phasellus pellentesque vehicula sapien, id tincidunt dolor adipiscing vel.
+
+Suspendisse potenti. Vivamus sed elit mi. Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac
+turpis egestas. Mauris sit amet erat nec nibh sodales ornare. Class aptent taciti sociosqu ad litora torquent per conubia
+nostra, per inceptos himenaeos. Vivamus nec tellus ligula, eget laoreet lacus. Nullam interdum elementum tellus sit
+amet interdum. Aenean vel lorem eu nunc eleifend ullamcorper sit amet eget quam. Curabitur at sapien nec metusmalesuada
+tristique. Etiam in pellentesque risus.
\ No newline at end of file
Added: karaf/branches/karaf-2.3.x/shell/commands/src/test/resources/org/apache/karaf/shell/commands/WcActionTestSmall.txt
URL: http://svn.apache.org/viewvc/karaf/branches/karaf-2.3.x/shell/commands/src/test/resources/org/apache/karaf/shell/commands/WcActionTestSmall.txt?rev=1479580&view=auto
==============================================================================
--- karaf/branches/karaf-2.3.x/shell/commands/src/test/resources/org/apache/karaf/shell/commands/WcActionTestSmall.txt (added)
+++ karaf/branches/karaf-2.3.x/shell/commands/src/test/resources/org/apache/karaf/shell/commands/WcActionTestSmall.txt Mon May 6 14:30:59 2013
@@ -0,0 +1,12 @@
+1
+2
+3
+4
+5
+6
+7
+8
+9
+10
+
+Hello World.
\ No newline at end of file