mirror of
https://github.com/on4kjm/FLEcli.git
synced 2025-01-18 21:01:10 +01:00
start coding the header processing
This commit is contained in:
parent
1adf11e8a0
commit
2e97cf3920
1 changed files with 16 additions and 0 deletions
16
cmd/load.go
16
cmd/load.go
|
@ -77,6 +77,13 @@ func loadFile() {
|
|||
regexpSingleMultiLineComment, _ := regexp.Compile("^{.+}$")
|
||||
regexpStartMultiLineComment, _ := regexp.Compile("^{")
|
||||
regexpEndMultiLineComment, _ := regexp.Compile("}$")
|
||||
regexpHeaderMyCall, _ := regexp.Compile("(?i)^mycall ")
|
||||
// regexpHeaderOperator, _ := regexp.Compile("(?i)^operator ")
|
||||
// regexpHeaderMyWwff, _ := regexp.Compile("(?i)^mywwff ")
|
||||
// regexpHeaderMySota, _ := regexp.Compile("(?i)^mysota ")
|
||||
// regexpHeaderQslMsg, _ := regexp.Compile("(?i)^qslmsg ")
|
||||
// regexpHeaderNickname, _ := regexp.Compile("(?i)^nickname ")
|
||||
// regexpHeaderDate, _ := regexp.Compile("(?i)^date ")
|
||||
|
||||
var isInMultiLine = false
|
||||
|
||||
|
@ -116,6 +123,15 @@ func loadFile() {
|
|||
// ** Process the data line
|
||||
// ****
|
||||
|
||||
//** is it a Header line?
|
||||
if(regexpHeaderMyCall.MatchString(eachline)) {
|
||||
myCallList := regexpHeaderMyCall.Split(eachline,-1)
|
||||
fmt.Println(len(myCallList))
|
||||
fmt.Println("myCallList", myCallList)
|
||||
fmt.Println(myCallList[1])
|
||||
continue
|
||||
}
|
||||
|
||||
fmt.Println(eachline)
|
||||
}
|
||||
}
|
Loading…
Reference in a new issue