#93: Updated README and migration script
This commit is contained in:
@@ -126,11 +126,11 @@ scripts/Migrations/Linux/AddUpdate.sh
|
||||
```
|
||||
Or you can manually add the migrations like so for each migration:
|
||||
```shell
|
||||
dotnet-ef migrations Add InitialCreate --context UserContext
|
||||
dotnet dotnet-ef migrations Add InitialCreate --context UserContext
|
||||
```
|
||||
Then update the migrations to the database like so<sup>*</sup>:
|
||||
```shell
|
||||
dotnet-ef database update --context UserContext
|
||||
dotnet dotnet-ef database update --context UserContext
|
||||
```
|
||||
|
||||
All of the contexts can be found in Database/Contexts folder.
|
||||
|
||||
@@ -1,28 +1,29 @@
|
||||
echo "Adding migrations..."
|
||||
|
||||
echo "Adding User migration"
|
||||
~/.dotnet/tools/dotnet-ef migrations add User --context UserContext
|
||||
dotnet dotnet-ef migrations add User --context UserContext
|
||||
echo "Adding Album migration"
|
||||
~/.dotnet/tools/dotnet-ef migrations add Album --context AlbumContext
|
||||
dotnet dotnet-ef migrations add Album --context AlbumContext
|
||||
echo "Adding Artist migration"
|
||||
~/.dotnet/tools/dotnet-ef migrations add Artist --context ArtistContext
|
||||
dotnet dotnet-ef migrations add Artist --context ArtistContext
|
||||
echo "Adding Genre migration"
|
||||
~/.dotnet/tools/dotnet-ef migrations add Genre --context GenreContext
|
||||
dotnet dotnet-ef migrations add Genre --context GenreContext
|
||||
echo "Adding Cover art migration"
|
||||
~/.dotnet/tools/dotnet-ef migrations add CoverArt --context CoverArtContext
|
||||
dotnet dotnet-ef migrations add CoverArt --context CoverArtContext
|
||||
echo "Adding Song migration"
|
||||
~/.dotnet/tools/dotnet-ef migrations add Song --context SongContext
|
||||
dotnet dotnet-ef migrations add Song --context SongContext
|
||||
|
||||
echo "Updating migrations.."
|
||||
echo "Updating User migration"
|
||||
~/.dotnet/tools/dotnet-ef database update --context UserContext
|
||||
dotnet dotnet-ef database update --context UserContext
|
||||
echo "Updating Album migration"
|
||||
~/.dotnet/tools/dotnet-ef database update --context AlbumContext
|
||||
dotnet dotnet-ef database update --context AlbumContext
|
||||
echo "Updating Artist migration"
|
||||
~/.dotnet/tools/dotnet-ef database update --context ArtistContext
|
||||
dotnet dotnet-ef database update --context ArtistContext
|
||||
echo "Updating Genre migration"
|
||||
~/.dotnet/tools/dotnet-ef database update --context GenreContext
|
||||
dotnet dotnet-ef database update --context GenreContext
|
||||
echo "Updating Cover art migration"
|
||||
~/.dotnet/tools/dotnet-ef database update --context CoverArtContext
|
||||
dotnet dotnet-ef database update --context CoverArtContext
|
||||
echo "Updating Song migration"
|
||||
~/.dotnet/tools/dotnet-ef database update --context SongContext
|
||||
dotnet dotnet-ef database update --context SongContext
|
||||
|
||||
|
||||
Reference in New Issue
Block a user