As an anonymous user, you can only add new data. If you would like to also modify existing data, please create an account and indicate your languages on your user page.

User:MartinMai/get latest.sh

From OmegaWiki
Jump to: navigation, search
#!/bin/bash
target_host='localhost'
target_user='root'
target_db='omegawiki'
target_pass=''

omegawiki_dir='/srv/www/htdocs/omegawiki'

wget --no-clobber -r http://omegawiki.org/downloads/omegawiki-latest.tgz
tar -xzf omegawiki-latest.tgz

mysql -v \
--host=$target_host --user=$target_user --pass=$target_pass \
--execute='CREATE DATABASE IF NOT EXISTS '$target_db \


mysql \
--host=$target_host --user=$target_user \
--pass=$target_pass -C $target_db  < omegawiki-latest.sql

wget --no-clobber -r http://omegawiki.org/downloads/rights.sql
mysql -v \
--host=$target_host --user=$target_user --pass=$target_pass \
< rights.sql

wget --no-clobber -r http://omegawiki.org/downloads/user.sql
mysql -v \
--host=$target_host --user=$target_user --pass=$target_pass \
--database=$target_db \
< user.sql

mkdir -p $omegawiki_dir
cd $omegawiki_dir
svn co http://svn.wikimedia.org/svnroot/mediawiki/branches/wikidata

cd $omegawiki_dir/wikidata/extensions/
svn co http://svn.wikimedia.org/svnroot/mediawiki/trunk/extensions/Wikidata

cd $omegawiki_dir
wget --no-clobber -r http://omegawiki.org/downloads/LocalSettings.samplecreated that DB-stuff

+----------------------------------------+
| Tables_in_omegawiki                    |
+----------------------------------------+
| archive                                |
| categorylinks                          |
| externallinks                          |
| filearchive                            |
| hitcounter                             |
| image                                  |
| imagelinks                             |
| interwiki                              |
| ipblocks                               |
| ipblocks_old                           |
| job                                    |
| langlinks                              |
| language                               |
| language_names                         |
| logging                                |
| math                                   |
| namespace                              |
| namespace_names                        |
| objectcache                            |
| oldimage                               |
| page                                   |
| page_backup_jul_07                     |
| page_restrictions                      |
| pagelinks                              |
| querycache                             |
| querycache_info                        |
| querycachetwo                          |
| recentchanges                          |
| redirect                               |
| revision                               |
| script_log                             |
| searchindex                            |
| site_stats                             |
| templatelinks                          |
| text                                   |
| trackbacks                             |
| transcache                             |
| user                                   |
| user_groups                            |
| user_newtalk                           |
| uw_alt_meaningtexts                    |
| uw_bootstrapped_defined_meanings       |
| uw_class_attributes                    |
| uw_class_membership                    |
| uw_collection                          |
| uw_collection_contents                 |
| uw_collection_language                 |
| uw_defined_meaning                     |
| uw_expression                          |
| uw_meaning_relations                   |
| uw_objects                             |
| uw_option_attribute_options            |
| uw_option_attribute_values             |
| uw_syntrans                            |
| uw_text                                |
| uw_text_attribute_values               |
| uw_transactions                        |
| uw_translated_content                  |
| uw_translated_content_attribute_values |
| uw_url_attribute_values                |
| watchlist                              |
| wikidata_sets                          |
+----------------------------------------+
62 rows in set (0.00 sec)