Skip to content

Commit 0b71af1

Browse files
fix: quote shell variables potentially containing white space
1 parent 631331c commit 0b71af1

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

graph-exploration-README.md

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@ A tutorial how to interactively explore the Common Crawl webgraphs – or other
1212
1313
$> mvn clean package
1414
15-
$> CC_WEBGRAPH=$PWD
16-
$> CC_WEBGRAPH_JAR=$PWD/target/cc-webgraph-*-jar-with-dependencies.jar
15+
$> CC_WEBGRAPH="$PWD"
16+
$> CC_WEBGRAPH_JAR="$PWD"/target/cc-webgraph-*-jar-with-dependencies.jar
1717
```
1818

1919
2. select a web graph you want to explore, choose a download directory and download the web graph
@@ -28,19 +28,19 @@ A tutorial how to interactively explore the Common Crawl webgraphs – or other
2828
About 15 GiB disk are needed to hold all files of a domain-level webgraph.
2929

3030
```
31-
$> $CC_WEBGRAPH/src/script/webgraph_ranking/graph_explore_download_webgraph.sh $GRAPH
31+
$> "$CC_WEBGRAPH"/src/script/webgraph_ranking/graph_explore_download_webgraph.sh $GRAPH
3232
```
3333

3434
3. Build the map from vertex label to vertex ID and vice versa. This allows to look up a reverse domain name (e.g. "org.commoncrawl") and get the corresponding vertex ID.
3535

3636
```
37-
$> $CC_WEBGRAPH/src/script/webgraph_ranking/graph_explore_build_vertex_map.sh $GRAPH $GRAPH-vertices.txt.gz
37+
$> "$CC_WEBGRAPH"/src/script/webgraph_ranking/graph_explore_build_vertex_map.sh $GRAPH $GRAPH-vertices.txt.gz
3838
```
3939

4040
4. Launch the [JShell](https://docs.oracle.com/en/java/javase/21/jshell/index.html)
4141

4242
```
43-
$> jshell --class-path $CC_WEBGRAPH_JAR
43+
$> jshell --class-path "$CC_WEBGRAPH_JAR"
4444
| Welcome to JShell -- Version 21.0.3
4545
| For an introduction type: /help intro
4646
@@ -69,9 +69,9 @@ A tutorial how to interactively explore the Common Crawl webgraphs – or other
6969
To make the loading easier, you may use the load script [graph_explore_load_graph.jsh](src/script/webgraph_ranking/graph_explore_load_graph.jsh) and pass the graph name as a Java property to the JShell via command-line option `-R-Dgraph=$GRAPH`
7070

7171
```
72-
$> jshell --class-path $CC_WEBGRAPH_JAR \
72+
$> jshell --class-path "$CC_WEBGRAPH_JAR" \
7373
-R-Dgraph=$GRAPH \
74-
$CC_WEBGRAPH/src/script/webgraph_ranking/graph_explore_load_graph.jsh
74+
"$CC_WEBGRAPH"/src/script/webgraph_ranking/graph_explore_load_graph.jsh
7575
Loading graph cc-main-2024-feb-apr-may-domain
7676
2024-06-23 13:30:14:134 +0200 [main] INFO Graph - Loading graph cc-main-2024-feb-apr-may-domain.graph
7777
2024-06-23 13:30:14:340 +0200 [main] INFO Graph - Loading transpose of the graph cc-main-2024-feb-apr-may-domain-t.graph
@@ -126,9 +126,9 @@ The methods are bundled in the classes of the Java package `org.commoncrawl.webg
126126
We start again with launching the JShell and loading a webgraph:
127127

128128
```
129-
$> jshell --class-path $CC_WEBGRAPH_JAR \
129+
$> jshell --class-path "$CC_WEBGRAPH_JAR" \
130130
-R-Dgraph=$GRAPH \
131-
$CC_WEBGRAPH/src/script/webgraph_ranking/graph_explore_load_graph.jsh
131+
"$CC_WEBGRAPH"/src/script/webgraph_ranking/graph_explore_load_graph.jsh
132132
jshell>
133133
```
134134

0 commit comments

Comments
 (0)