Îõ³h&2-.¦      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ ¡¢£¤¥  Safe-Inferredñ¦§¨©ª«¬­None  #$%-?ÔÙ Õrefurb:Data type of a migration, with its key, type, and actions.refurbÌSchema for the migration to run in, which also qualifies the migration key."refurb¤Unique key to identify this migration among all known migrations. Never reuse keys, as they're the only link between the stored migration log and known migrations.refurbWhat type of migration this is.refurbÐOptional action to execute before the primary execution to verify preconditions.refurbÀMain migration action, such as creating tables or updating data.refurbûConstraint for actions run in the context of a migration, with access to underlying IO, PostgreSQL connection, and logging.refurb;Enumeration of the types of migration that are known about.refurbÏMigration that updates the schema of the database and should be run everywhere.refurbäMigration that installs or replaces data for testing purposes and should never be run in production.refurbÅStructure with connection information for connecting to the database.refurb0Hostname or IP address of the PostgreSQL server.refurb9Port number the PostgreSQL server is running on (usually 5432).refurb(What user to connect to the database as. refurb.What password to connect to the database with.!refurb4What database in the PostgreSQL server to attach to."refurbGiven a ò make up the real connection string to pass when connecting to the database. Includes password, so never log this.#refurbGiven a Ô make up the log-safe connection string to show to humans, which omits the password.$refurb4The fully qualified key of the migration, schema.key,refurbHelper to construct a  type 5 with the given execution action and no check action.-refurbHelper to construct a  type 5 with the given execution action and no check action..refurbAttach a check function to a .! "#$'()*+,-.! "#*)+'($,-.None &?ù/refurbÛSimple quasiquoter which just makes it easier to embed literal chunks of SQL in migrations. For example: Ç createStuffIndex :: MonadMigration m => m () createStuffIndex = execute_ [qqSql| create index stuff_index on stuff (things) where is_what_we_want_to_index = t |] 0refurbÎQuasiquoter which takes a block of literal SQL and converts it into a list of ® values, e.g. to pass to 4Ü. A semicolon at the beginning or end of a line (sans whitespace) separates SQL statements. For example: É createStuff :: MonadMigration m => m () createStuff = executeSeries_ [qqSqls| create sequence stuff_seq; create table stuff ( id bigint not null primary key default nextval( stuff_seq) ); |] 1refurbÇExecute some parameterized SQL against the database connection. Wraps ¯ using the  reader to get the connection.2refurbÇExecute some parameterized SQL against the database connection. Wraps ° using the  reader to get the connection.3refurb?Execute some fixed SQL against the database connection. Wraps ± using the  reader to get the connection.4refurböExecute a series of fixed SQL statements against the database connection. Equivalent to `traverse_ (void . execute_)`5refurbÂRun a parameterized query against the database connection. Wraps ² using the  reader to get the connection.6refurb:Run a fixed query against the database connection. Wraps ³ using the  reader to get the connection.7refurb=Run an Opaleye query against the database connection. Wraps ´ using the  reader to get the connection.8refurbRun an Opaleye µ! against the database connection.9refurbRun an Opaleye ¶! against the database connection.:refurbRun an Opaleye ·! against the database connection.;refurb#Check if a schema exists using the information_schema views.<refurb.Check if a table exists in a schema using the information_schema views.=refurb:Check if a column exists in a schema on a table using the information_schema views./0123456789:;<=/0123456789:;<=None &/>?ÀÁÂÖ×m >refurb9Result of running a migration, either success or failure.Hrefurb,Columns of the Refurb config in the databaseIrefurb%Fields of the Refurb config in memoryJrefurbÕColumns of a migration log when inserting into the database (with ID column optional)KrefurbÃColumns of a migration log when reading from the database (with ID)Lrefurb×Fields of a migration log entry to insert in the database (with the ID column optional)MrefurbÍFields of a migration log entry in memory fetched from the database (with ID)nrefurbÏThe migration log table which records all executed migrations and their resultsorefurbâThe refurb config table which controls whether this database is considered a production one or notprefurbÞTest to see if the schema seems to be installed by looking for an existing refurb_config tableqrefurbàCheck if this database is configured as a production database by reading the refurb config tablerrefurbÃCreate the refurb schema elements. Will fail if they already exist.srefurb“Read the migration log and stitch it together with the expected migration list, forming a list in the same order as the known migrations but with ¸Ò representing whether the migration log for the known migration is present or not.¹ migration4 represents a known migration that has no log entry.º migrationLog> represents an unknown migration that was applied in the past.¸ migration migrationLogÅ represents a migration that has an attempted application in the log.À >@?CHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrsÀ>@?C mlkjihgfedcba`_^]\[ZYXWVUTSRQPONMLKJIHnopqrsNone trefurbÀStructure holding the parsed command line arguments and options.vrefurb/Whether to turn on debug logging to the consolewrefurb"Whether to colorize console outputxrefurb×The configuration file where (presumably) the database connection information is storedyrefurb=Which command the user chose and the options for that commandzrefurbÀThe various top level commands that can be requested by the user{refurbÞMigrate the database or show what migrations would be applied, possibly backing up beforehand.|refurbShow the migration status.}refurb:Show status of a particular migration with its log output.~refurbBack up the database.refurbNewtype wrapper for the --seed boolean (True if given, False if omitted)refurbNewtype wrapper for the --backup-first option to the migrate command.ƒrefurbNewtype wrapper for the  --execute boolean (True if given, False if omitted)…refurbOption parser for the migrate command†refurbOption parser for the show-log command‡refurbOption parser for the show-migration commandˆrefurbOption parser for the backup command‰refurb%Parser for the command line argumentstuwxyvz~}|{€‚ƒ„…†‡ˆ‰ƒ„‚€z~}|{…†‡ˆtuwxyv‰None -?à$Ø ’refurbÅConstraint of actions for command execution, including access to the “, logging, and underlying IO.“refurb—Reader context for all command execution which contains the command line options, database connection and connection information, and known migrations.•refurbThe t+ structure parsed from the command line by  Refurb.Cli.–refurbThe open database ».—refurbÞThe information used to connect to the database, required for running command line tools like pg_dump against the same database.˜refurb"The known migrations passed in to  .™refurb0Given the configuration implicitly available to ’Ä, produce a function which possibly strips ANSI colorization from a ¼) if the user requested colorless output.šrefurb0Given the configuration implicitly available to ’#, produce a function which emits a ¼Ç on stdout that is colored unless the user requested colorless output.›refurbProduce a colorized ¼ with success or failure, based on which > value was passed. ’“”•˜–—™š› “”•˜–—’™š›None  &?É×&¾œrefurb$Given a migration status as read by s5, pretty print that information as a table on stdout.refurbImplement the show-logÄ command by reading the entire migration log and displaying it with œ.žrefurbImplement the show-migrationß command by reading migration log pertaining to the given migration key and displaying it with œ plus its log output.œžœžNone #$?'PŸrefurb Handle the backup command by calling pg_dump to save a database backup.ŸŸNone ?è*Ì refurb*Helper which produces the standard prefix ¼ for a given migration: migration key:  with color.¡refurbImplement the migrateè command by verifying that seed data is only applied to non-production databases, reading the migration status, and determining from that status which migrations to apply. If the user requested execution of migrations, delegate to ¢ to actually do the work.¢refurbGiven a pre-vetted list of ˜ structures to apply to the database, iterate through them and run their check actions (if any) followed by execution actions with log output captured.£refurb Format a ½) in the way we want for logging output - #package:module filename:line:column¤refurbÅFormat the current timestamp in the way we want for logging output - yyyy-mm-dd hh:mm:ss.SSS ¡¢£¤ ¡¢£¤ None #$-â¥refurb"Main entry point for refurbishing.In .refurb readDatabaseConnectionString migrations, readDatabaseConnectionStringŒ is a function taking the configuration file path from the command line and yielding a pair of actual and loggable connection strings, and  migrations is a list of  records to consider. For example: & module Main where import Refurb (, , 3, , , refurbMain) migrations :: [ƒ] migrations = [ schemaMigration "create-my-table" createMyTable ] createMyTable :: MonadMigration m => m () createMyTable = void $ execute_ "create table my_table (...)" main :: IO () main = refurbMain readDatabaseConnInfo migrations - !"#$'()*+,-./0123456789:;<=¥¥¾   !"#$%&&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~~€‚ƒ„…†‡ˆˆ‰‰ŠŠ‹ŒŽ‘’“”•–—˜™™š›œžŸ ¡¢£¤¥¦§¨© ª « ¬ ­ ® ¯ ° ±²³´²µ;²µ<²¶=²µ?²µ@·¸¹·º»·ºC·ºD¼½¾¼½¿¼½À²¶ÁÂÃÄÅÆÇÈrefurb-0.3.0.2-inplace Refurb.Store Refurb.TypesRefurb.MigrationUtils Refurb.CliRefurb.Run.InternalRefurb.Run.InfoRefurb.Run.BackupRefurb.Run.MigrateRefurb Paths_refurb refurbMainFIdFIdMayCIdCIdMay FQualifiedKey CQualifiedKeyFAppliedCAppliedFOutputCOutputFResultCResult FDuration CDuration FProdSystem CProdSystem Migration_migrationSchema _migrationKey_migrationType_migrationCheck_migrationExecuteMonadMigration MigrationTypeMigrationSchemaMigrationSeedDataConnInfoconnHostconnPortconnUser connPassword connDbNameconnInfoAsConnStringconnInfoAsLogStringmigrationQualifiedKey$fEqMigrationType$fShowMigrationTypemigrationCheckmigrationExecute migrationKeymigrationSchema migrationTypeschemaMigrationseedDataMigration withCheckqqSqlqqSqlsexecute executeManyexecute_executeSeries_queryquery_runQuery runInsertMany runUpdate runDeletedoesSchemaExistdoesTableExistdoesColumnExistMigrationResultMigrationSuccessMigrationFailure$fEqMigrationResult$fShowMigrationResultPGMigrationResult$fFromFieldMigrationResult&$fDefaultToFieldsMigrationResultField_2$fDefaultFromFieldPGMigrationResultMigrationResult$fIsSqlTypePGMigrationResultRefurbConfigCols RefurbConfigMigrationLogColsWMigrationLogColsR MigrationLogW MigrationLogfId_fIdMay_cId_cIdMay_fQualifiedKey_cQualifiedKey_ fApplied_ cApplied_fOutput_cOutput_fResult_cResult_ fDuration_ cDuration_ fProdSystem_ cProdSystem_fIdfIdMaycIdcIdMay fQualifiedKey cQualifiedKeyfAppliedcAppliedfOutputcOutputfResultcResult fDuration cDuration fProdSystem cProdSystem migrationLog refurbConfigisSchemaPresent isProdSysteminitializeSchemareadMigrationStatusOptsdebugcolorize configFilecommandCommandCommandMigrateCommandShowLogCommandShowMigration CommandBackupInstallSeedDataPreMigrationBackupGoNoGocommandMigrateParsercommandShowLogParsercommandShowMigrationParsercommandBackupParser optsParser $fEqCommand $fShowCommand$fEqInstallSeedData$fShowInstallSeedData$fEqPreMigrationBackup$fShowPreMigrationBackup $fEqGoNoGo $fShowGoNoGo MonadRefurbContextcontextOptions contextDbConncontextDbConnInfocontextMigrationsoptionallyColorMoptionallyColoredMmigrationResultDocshowMigrationStatusshowLog showMigrationbackupmigrationPrefixDocmigrateapplyMigrations locLogString nowLogStringversion getBinDir getLibDir getDynLibDir getDataDir getLibexecDir getSysconfDirgetDataFileName.postgresql-simple-0.6.4-KZFmmiZVYzE1XYrc37iRki Database.PostgreSQL.Simple.TypesQueryDatabase.PostgreSQL.Simple#Database.PostgreSQL.Simple.Internal&opaleye-0.9.2.0-8pG7Sfc1Q9wHQsyGav68lNOpaleye.RunSelect runSelectOpaleye.Manipulation runInsert$these-1.1.1.1-GLVLRUZrP8O2Upyh1zZcpg Data.TheseTheseThisThat Connection+ansi-wl-pprint-0.6.9-3LMlxc44XAfG686KENkRCz%Text.PrettyPrint.ANSI.Leijen.InternalDoctemplate-haskellLanguage.Haskell.TH.SyntaxLoc