-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtodo.txt
More file actions
130 lines (59 loc) · 4.93 KB
/
todo.txt
File metadata and controls
130 lines (59 loc) · 4.93 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
raw repo.. just exposing ISession.
cant do help from powershell
when a new database is created and existing migrations exist, it doesn't run. Think it needs to always check to
1) see if DB exists, or not create it
2) see if migration table is created, if not create it.
when creating db it for some reason wont create the migration log table at the same time.
add ability to have details sql / nhibernate logging... both show sql and having a logger.
try and get one base IRepo class - or update docs to reflect this change
on enable migration test if DB exists, if not try and create it.
-----------------
EXE runner examples:
enable-migrations "E:\Work\nhibernateRepo\NHibernateRepository\Test\ExampleRepo\ExampleRepo.csproj" -repo examplerepo -configFile "E:\Work\nhibernateRepo\NHibernateRepository\Test\ExampleRepo\App.config"
add-migration "E:\Work\nhibernateRepo\NHibernateRepository\Test\ExampleRepo\ExampleRepo.csproj" -repo examplerepo -configFile "E:\Work\nhibernateRepo\NHibernateRepository\Test\ExampleRepo\App.config" -filename add_mad_migration
update-database "E:\Work\nhibernateRepo\NHibernateRepository\Test\ExampleRepo\ExampleRepo.csproj" -repo examplerepo -confiGfile "E:\Work\nhibernateRepo\NHibernateRepository\Test\ExampleRepo\App.config"
-----------------
Error checking and nice message to user that if they try and add a migration before a config is added they know why it failed.
clean up and write explaination of test area, example project.
update readme to explain repocombined and repo split
update readme to include auto mapper settings info
update readme to explain that the project you point at for the model TEntity will find all classes and try and map them to the db, will only exlude some class types.
ensure that paths in powershell can be relative, dont have to fully path.
make a migration completely transactional. all executesql commands in one transaction.. probably do not use nhibernate at all at that point.
once all working and happy and committed => make another repo that is called naked or something... just exposes ISession, but allows to take advantage of migration stuff.
Will need to think about how to do the setup stuff. If it is all naked then they will need to config things are loaded from.. try and make it use the same setup process if possible.
----
(not in order yet)
figure out when powershell script is run how it knows which project to look in for repo stuff, does it get full file path?
be able to tell the schema creator which project to look in for Irepo implementation
run all instances of IRepo
when adding a migration should check that all previous migrations have already been run.
figure out how to run all scripts from IRepo
log when a file has been run
before a file is run check if it has already been executed.
Think about how to deal with Users wanting to include / exclude types in the configuration.
---------------------------------------------------------------------------------------
want to reproduce EF style migrations
add migration
update database
automatic migrations or manual
---------------------------------------------------------------------------------------
getting Repo to deal with migrations:
adding powershell scripts to PMC (need to be done via nuget)
http://haacked.com/archive/2011/04/19/writing-a-nuget-package-that-adds-a-command-to-the.aspx/
http://stackoverflow.com/questions/27807102/how-to-add-commands-to-visualstudio-console
http://blogs.msmvps.com/matthieu/2014/06/02/extend-visual-studio-with-nuget-powershell-commands-basis/
powershell script helpers to get powershell to check a certain project for config file stuff:
https://docs.nuget.org/consume/package-manager-console-powershell-reference
getting the selected project in the PMC:
Get-Project
Gets the specified project. If none is specified, returns the default project.
Get-Project [[-Name] <string>] [-All]
Returns a reference to the DTE (Development Tools Environment) for the specified project. If none is specified, returns the default project selected in the Package Manager Console.
http://stackoverflow.com/questions/18544354/how-to-programmatically-include-a-file-in-my-project
http://stackoverflow.com/questions/18020062/how-to-add-an-existing-item-to-a-project-programmatically
http://stackoverflow.com/questions/9857504/add-existing-item-in-vs2010-project-programmatically
figuring a way to add files and folders to a CSPROJ file from powershell
https://msdn.microsoft.com/en-us/library/ms228772%28VS.80%29.aspx?f=255&MSPPError=-2147217396
https://gallery.technet.microsoft.com/scriptcenter/9db8e065-bed4-4944-991f-058639b6de48
http://stackoverflow.com/questions/17382308/include-file-in-project-from-command-line