<commit_before>Coshx::Application.routes.draw do

  # eg www.coshx.com redirects to coshx.com
  #   http://stackoverflow.com/a/7352878/283398
  match '(*any)' => redirect { |p, req| req.url.sub('www.', '') }, :constraints => { :host => /^www\./ }

  devise_for :admins
  
  match 'dashboard' => 'dashboard#index', :as => :admin_root
  match '/feed' => 'posts#feed', :as => :feed, :defaults => { :format => 'atom' }

  resources :posts, :path => "/blog" do
    put 'publish', :on => :member
    get ':year/:month/:day/:title' => 'posts#show', :on => :collection, :as => :show
  end

  resources :jobs, :path => "/careers" do
    put 'publish', :on => :member
  end

  match '/services' => 'home#services', :as => :services
  match '/portfolio' => 'home#portfolio', :as => :portfolio
  match '/about' => 'home#about', :as => :about
  root :to => 'home#index'
end
<commit_msg>Splits blog routes into 2 namespaces<commit_after>Coshx::Application.routes.draw do

  # eg www.coshx.com redirects to coshx.com
  #   http://stackoverflow.com/a/7352878/283398
  match '(*any)' => redirect { |p, req| req.url.sub('www.', '') }, :constraints => { :host => /^www\./ }

  devise_for :admins
  
  match 'dashboard' => 'dashboard#index', :as => :admin_root
  match '/feed' => 'posts#feed', :as => :feed, :defaults => { :format => 'atom' }

  resources :posts, :path => "/blog", :only => :index do
    get ':year/:month/:day/:title' => 'posts#show', :on => :collection, :as => :show
  end

  resources :posts, :except => :index do
    put 'publish', :on => :member
  end

  resources :jobs, :path => "/careers" do
    put 'publish', :on => :member
  end

  match '/services' => 'home#services', :as => :services
  match '/portfolio' => 'home#portfolio', :as => :portfolio
  match '/about' => 'home#about', :as => :about
  root :to => 'home#index'
end

{'fraction_non_alphanumeric': 0.21428571428571427, 'fraction_numerical': 0.014721919302071973, 'mean_word_length': 3.6455696202531644, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 51, 'https://': 0, 'lorem ipsum': 0, 'www.': 6, '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': '1824944', 'n_tokens_mistral': 675, 'n_tokens_neox': 651, 'n_words': 169}