Making a Theme With Bones: Cleaning Up

This entry is part 3 of 3 in the series Making a Theme With Bones

We will strip unnecessary parts from a fresh theme made with Bones.


Delete, Delete, Delete

Cleaning picture by inf3ktion, flickr
Cleaning / inf3ktion, flickr

The first two parts (Getting Started and Finishing Off) of the series about making a state of the art website with Bones. I’m working with that modified theme for this article. Bones is an excellent and very detailed starter theme.

I’ve been using Bones as a starting point for my projects and its absolutely thorough HTML5 code with the most comprehensive and highly detailed stylesheet I’ve ever seen.

But when the time is ready to put the final theme into production it is important to remove the parts that we don’t need.

Bones grows every day. It’s great for personal projects and clients alike. Download it, Customize it, and make it yours. It’s a strong foundation for every project.

It’s no secret there are a lot of PHP and other files that we should remove from the directories of our theme. For our purpose (no custom pages, translations, or taxonomies) this is a process that is preferable, but if you have other plans or needs, please act accordingly and consider these steps one by one.


Step 1: General Files in Root

Folder by XXC, flickr
Folder / XXC, flickr

We already have got a favicon set from another directory so this file should be deleted along with the readme and .gitignore file. The readme is the usual description file about the package. So delete these:

bones2/..
	README
	.gitignore
	favicon.ico

Step 2: Files in Library Root

Windows 7 folder by Wysz, flickr
Windows 7 folder / Wysz, flickr

Delete these, because we don’t need styled admin pages or adding custom post types. The log.txt file is a report about the changes made through versions.

bones2/library/..
	admin.php
	custom-post-type.php
	log.txt

Step 3: Files for Custom Subpages

Picture by ewedistrict, flickr
Net / ewedistrict, flickr

We don’t need custom version of the archive, single page, post page and taxonomy page, so delete these:

bones2/..
	archive-custom_type.php
	page-custom.php
	single-custom_type.php
	taxonomy-custom_cat.php

Step 4: Translation Files

Country flags by mdanys, flickr
Country flags / mdanys, flickr

By default, translation files are not enabled, so let’s delete these as well:

bones2/library/translation/..
	de_DE.mo
	de_DE.po
	default.mo
	default.po
	es_ES.mo
	es_ES.po
	fr_FR.mo
	fr_FR.po
	he_IL.mo
	he_IL.po
	README
	translation.php
	zh_CN.mo
	zh_CN.po

Step 5: LESS or SCSS (SASS)

LESS and SASS CSS languages logos

These two languages have similar features and syntax but also have differences so it is important that you will use either LESS or SCSS and then you can delete the other one.


Step 6: Standard WordPress Pages

WordPress logo button by titanas, flickr
WordPress logo button / titanas, flickr

To opt for the standard WordPress look we can consider even deleting more files, like 404.php, archive.php or search.php.

Tip: For more speed you can create your own custom script (batch on Windows or bash on Mac or Linux) which will delete contents which are unnecessary.


Summary

This article was aimed only at a general overview about cleaning up a modified Bones theme like this. If you are not sure about one of the steps, then ask a developer or leave that part untouched (better safe than sorry!). Before you begin this deleting process, make sure you have a complete backup! Happy cleaning!

from Wptuts+ http://wp.tutsplus.com/tutorials/theme-development/making-a-theme-with-bones-cleaning-up/

About these ads

Kommentar verfassen

Bitte logge dich mit einer dieser Methoden ein, um deinen Kommentar zu veröffentlichen:

WordPress.com-Logo

Du kommentierst mit Deinem WordPress.com-Konto. Abmelden / Ändern )

Twitter-Bild

Du kommentierst mit Deinem Twitter-Konto. Abmelden / Ändern )

Facebook-Foto

Du kommentierst mit Deinem Facebook-Konto. Abmelden / Ändern )

Google+ photo

Du kommentierst mit Deinem Google+-Konto. Abmelden / Ändern )

Verbinde mit %s