Set up the filters required to ignore local dev config.
This commit is contained in:
parent
a375a4356a
commit
03fb0b58fd
5 changed files with 16 additions and 1 deletions
1
.gitattributes
vendored
Normal file
1
.gitattributes
vendored
Normal file
|
@ -0,0 +1 @@
|
|||
/Website/appsettings.Development.json filter=clean-config
|
2
.gitconfig
Normal file
2
.gitconfig
Normal file
|
@ -0,0 +1,2 @@
|
|||
[filter "clean-config"]
|
||||
clean = ./clean-config.sh
|
|
@ -4,6 +4,9 @@ Old repo: https://git.robware.uk/rob/Robware
|
|||
|
||||
My old repo was my attempt at an MVC framework. While I learned a lot about how to make an MVC framework, it was quite a pain to keep up. Now I'm using .NET Core ASP MVC. I much prefer C# and the whole thing is much nicer to work with.
|
||||
|
||||
## Setup
|
||||
After clone, please run `git config --local include.path ../.gitconfig`. This will set up the filters required to ignore local dev config.
|
||||
|
||||
## Changes on previous implementation:
|
||||
* Not PHP
|
||||
* Use markdown for blog posts instead of own rolled markup solution
|
||||
|
|
|
@ -8,5 +8,7 @@
|
|||
},
|
||||
"ConnectionStrings": {
|
||||
"database": "Server=localhost;User ID=user;Password=pass;Database=db"
|
||||
}
|
||||
},
|
||||
"gitDomain": "",
|
||||
"gitToken": ""
|
||||
}
|
7
clean-config.sh
Normal file
7
clean-config.sh
Normal file
|
@ -0,0 +1,7 @@
|
|||
#!/bin/sh
|
||||
|
||||
sed \
|
||||
-e 's/"database": "Server=.*;User ID=.*;Password=.*;Database=.*"/"database": "Server=localhost;User ID=user;Password=pass;Database=db"/g' \
|
||||
-e 's/"gitDomain": ".*"/"gitDomain": ""/g' \
|
||||
-e 's/"gitToken": ".*"/"gitToken": ""/g' \
|
||||
$1
|
Loading…
Add table
Add a link
Reference in a new issue