forked from rho_n/hpr_generator
Add database creation helper scripts
Add a script to create an empty database and a script to create a database filled with data from the Insert_Test_Data script.
This commit is contained in:
parent
d0443f0a7d
commit
5bacbcec28
@ -4,6 +4,9 @@ Static web page generator for the Hacker Public Radio website.
|
||||
## Installation
|
||||
* Clone or download this repository
|
||||
* Create the sqlite3 database from the files in the _sql directory. The default name for the database file is "hpr.db" and should be located in the root of the project directory. The name and location can be set in the site.cfg file.
|
||||
* Two sql helper scripts are available to generate an empty database or a database filled with test data.
|
||||
- For an empty database: `cat Create_Database_Empty.sql | sqlite3 hpr.db`
|
||||
- For a database with test data: `cat Create_Database_Test.sql | sqlite3 hpr.db`
|
||||
* Install the needed Perl modules using preferred method (distribution packages, CPAN, etc.)
|
||||
* GetOpt
|
||||
* Pod::Usage
|
||||
|
4
_sql/Create_Database_Empty.sql
Normal file
4
_sql/Create_Database_Empty.sql
Normal file
@ -0,0 +1,4 @@
|
||||
.read Create_Table_Contributors.sql
|
||||
.read Create_Table_Episodes.sql
|
||||
.read Create_Table_Tags.sql
|
||||
.read Create_Table_Tag_To_Episodes.sql
|
2
_sql/Create_Database_Test.sql
Normal file
2
_sql/Create_Database_Test.sql
Normal file
@ -0,0 +1,2 @@
|
||||
.read Create_Database_Empty.sql
|
||||
.read Insert_Test_Data.sql
|
@ -32,6 +32,9 @@ This is a site generator for the Hacker Public Radio website based upon the Perl
|
||||
* Create the sqlite3 database from the files in the _sql directory. The default name for the
|
||||
database file is "hpr.db" and should be located in the root of the project directory. The
|
||||
name and location can be set in the site.cfg file.
|
||||
* Two sql helper scripts are available to generate an empty database or a database filled with test data.
|
||||
- For an empty database: `cat Create_Database_Empty.sql | sqlite3 hpr.db`
|
||||
- For a database with test data: `cat Create_Database_Test.sql | sqlite3 hpr.db`
|
||||
* Install the needed Perl modules using preferred method (distribution packages, CPAN, etc.)
|
||||
* GetOpt
|
||||
* Pod::Usage
|
||||
|
Loading…
Reference in New Issue
Block a user