replace header name
This commit is contained in:
@@ -4,6 +4,7 @@ package main
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
"archive/zip"
|
"archive/zip"
|
||||||
|
"bufio"
|
||||||
"bytes"
|
"bytes"
|
||||||
"fmt"
|
"fmt"
|
||||||
"io"
|
"io"
|
||||||
@@ -80,7 +81,18 @@ func main() {
|
|||||||
f.Close()
|
f.Close()
|
||||||
log.Fatal(err)
|
log.Fatal(err)
|
||||||
}
|
}
|
||||||
_, err = io.Copy(f, zr)
|
scanner := bufio.NewScanner(zr)
|
||||||
|
for scanner.Scan() {
|
||||||
|
text := scanner.Text()
|
||||||
|
if text == `#include "sqlite3.h"` {
|
||||||
|
text = `#include "sqlite3-binding.h"`
|
||||||
|
}
|
||||||
|
_, err = fmt.Fprintln(f, text)
|
||||||
|
if err != nil {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
err = scanner.Err()
|
||||||
if err != nil {
|
if err != nil {
|
||||||
zr.Close()
|
zr.Close()
|
||||||
f.Close()
|
f.Close()
|
||||||
|
|||||||
Reference in New Issue
Block a user