Skip to content

Commit d124cff

Browse files
committed
WIP general about file
1 parent 3c770f1 commit d124cff

1 file changed

Lines changed: 31 additions & 1 deletion

File tree

PSql.Deploy/en-US/about_PSql_Deploy.help.txt

Lines changed: 31 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,9 @@ a target database. A seed is a SQL script that populates a target database
1515
with data. Together, migrations and seeds provide a mechanism to perform
1616
database deployments in a controlled and repeatable manner.
1717

18+
PSql.Deploy is designed to integrate with the PSql module if it is installed,
19+
but PSql is not required.
20+
1821

1922
:: Source Directory Structure ::
2023

@@ -50,8 +53,35 @@ src\ The source directory: a set of migrations and
5053
└─ ... PSql.Deploy does not care about other files or
5154
directories present in the source directory.
5255

56+
Given an arbitrary source directory, PSql.Deploy expects to find migrations in
57+
a Migrations subdirectory and seeds in a Seeds subdirectory. Within the
58+
Migrations and Seeds directories, each subdirectory containing a _Main.sql file
59+
is a migration or seed, respectively. The name of the subdirectory determines
60+
the name of the migration or seed.
61+
62+
The _Main.sql file is a T-SQL script and is the entry point for the migration
63+
or seed. PSql.Deploy supports the SQLCMD features GO, $(…), :r, and :setvar,
64+
enabling authors to split migration and seed scripts across multiple files.
65+
PSql.Deploy also recognizes a few migration- and seed-specific directives.
66+
These are 'magic' comments that begin with --# but are ignored by other tools.
67+
68+
See about_PSql_Deploy_Migrations and about_PSql_Deploy_Seeds for more details.
69+
70+
71+
:: Command Overview ::
72+
73+
Get-SqlMigrations
74+
Lists migrations found in a source directory or applied to a target
75+
database.
76+
77+
Invoke-SqlMigrations
78+
Applies outstanding migrations to one or more target databases.
79+
80+
Invoke-SqlSeed
81+
Applies one or more seeds to one or more target databases.
82+
5383

54-
:: Target Parameter ::
84+
:: -Target Parameter ::
5585

5686
Most PSql.Deploy cmdlets accept a -Target parameter to specify one or more
5787
target databases on which to operate.

0 commit comments

Comments
 (0)