summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xsrc/doc1
-rw-r--r--src/file.c4
-rw-r--r--src/main.c2
3 files changed, 5 insertions, 2 deletions
diff --git a/src/doc b/src/doc
index 70a0a54..4c52852 100755
--- a/src/doc
+++ b/src/doc
@@ -1629,6 +1629,7 @@ Commands for handling cell content:
--txtdelim="\t"
--txtdelim=","
--txtdelim=";"
+ --txtdelim="|"
If you pass a .xlsx file to SC-IM, you can specify which sheet to load
with the --sheet parameter, which can be the name or number of a sheet.
diff --git a/src/file.c b/src/file.c
index 8d13c48..7ef633e 100644
--- a/src/file.c
+++ b/src/file.c
@@ -193,7 +193,7 @@ int modcheck() {
*
* \details This function checks the type of a file as well as txtdelim conf value
*
- * \return one of , ; \t
+ * \return one of , ; \t |
*/
char get_delim(char *type) {
@@ -208,6 +208,8 @@ char get_delim(char *type) {
delim = ',';
} else if (!strcasecmp(get_conf_value("txtdelim"), ";")) {
delim = ';';
+ } else if (!strcasecmp(get_conf_value("txtdelim"), "|")) {
+ delim = '|';
}
}
return delim;
diff --git a/src/main.c b/src/main.c
index cdf0a50..6f55fd7 100644
--- a/src/main.c
+++ b/src/main.c
@@ -864,7 +864,7 @@ void show_usage_and_quit(){
\n --quit_afterload Quit after loading all the files\
\n --sheet=SHEET Open SHEET when loading xlsx file. Default is 1.\
\n --tm_gmtoff={seconds} set gmt offset used for converting datetimes to localtime.\
-\n --txtdelim={\",\" or \";\" or \"\\t\"} Sets delimiter when opening a .tab of .csv file");
+\n --txtdelim={\",\" or \";\" or \"\\t\" or \"|\"} Sets delimiter when opening a .tab of .csv file");
#ifdef XLSX
printf("\n\
\n --xlsx_readformulas Set variable 'xlsx_readformulas'");