<commit_before># Setup attendee wiki.
# NOTE Apache site is managed by the 'my_bridgepdx_wordpress' recipe.

# The app used to live at another directory
old_dir = "/var/www/bridgepdx_wiki"
sitedir = "/var/www/bridgepdx_wiki_2009"

# Move directory over if found
if mv(old_dir, sitedir)
  service_manager.tell "apache2", "reload"
end

# Create directory
mkdir_p(sitedir) and chperm(sitedir, :user => default_user, :group => default_group)

# Add task to dump database to file
cronedit(default_user) do
  delete "17 * * * * (cd #{old_dir} && rake --silent dump)"
  delete "18 * * * * if test -f #{old_dir}/Rakefile; then (cd #{old_dir} && rake --silent dump); fi"
  delete "18 * * * * if test -f #{old_dir}/LocalSettings.php; then (cd #{old_dir} && rake --silent dump); fi"
  append "18 * * * * if test -f #{sitedir}/LocalSettings.php; then (cd #{sitedir} && rake --silent dump); fi"
end<commit_msg>my_bridgepdx_wiki_2009: Don't move aside /var/www/bridgepdx_wiki.<commit_after># Setup attendee wiki.
# NOTE Apache site is managed by the 'my_bridgepdx_wordpress' recipe.

# Create directory
sitedir = "/var/www/bridgepdx_wiki_2009"
mkdir_p(sitedir) and chperm(sitedir, :user => default_user, :group => default_group)

# Add task to dump database to file
cronedit(default_user) do
  append "18 * * * * if test -f #{sitedir}/LocalSettings.php; then (cd #{sitedir} && rake --silent dump); fi"
end
{'fraction_non_alphanumeric': 0.13731128684399713, 'fraction_numerical': 0.01653486700215672, 'mean_word_length': 4.590361445783133, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 4, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1536548', 'n_tokens_mistral': 517, 'n_tokens_neox': 494, 'n_words': 152}