Elive E17 Compiz

Elive is an Operating System built on top of Debian GNU/Linux, customized to offer users eye-candy OS experience with minimal hardware requirements.

The video below uses Enlightenment 17 on top of Elive and a special version of Compiz called Ecomorph to achieve the eye-candy effects.

Download: http://www.elivecd.org/Download/e17-compiz

Subversion: How to copy a branch to an empty trunk

Here’s the scenario:

You have this really cool idea of an OSS project and you have already coded some of its source, though not stable enough for release you’d decided to create and uploaded it on Google Code repository to track the development history. “Trunk tree should only have the stable source”, with this in mind you’d decided to create a branch directory (/1.0) and upload your unstable source in there. After days of hacking and cracking, you finally have a source candidate for the trunk tree. So, how do you copy your candidate branch to the empty trunk?

Remember that when you create a new project on Google Code, your initial repository will already have a branches, tags, and trunk tree.

Using “svn merge” will not do, because you still have an empty trunk.

But how about “svn copy“?

> svn copy https://your-project.googlecode.com/svn/branches/1.0 \
   https://your-project.googlecode.com/svn/trunk/

That wouldn’t do either. Yes it’ll copy all the files and directories inside the “/branch/1.0” directory but it’ll include the “/1.0” directory. Meaning the end result will be “/trunk/1.0“.

https://your-project.googlecode.com/svn/trunk/1.0

You don’t want that, do you? Remember that Trunk directory should always contain the latest and stable source. So the “/1.0” directory will be inappropriate. What you wanted to achieve in your project repository tree, is to look like this:

  • /svn/branches
    • /1.0
      • source.file.1
      • source.file.2
  • /tags
  • /trunk
    • source.file.1
    • source.file.2

Solution

The way to do this (without temporarily deleting the trunk directory) is to first, checkout the candidate branch, change working directory and import.

  1. Checkout the candidate/stable branch:
    > svn co https://your-project.googlecode.com/svn/branches/1.0 branch-1.0
    > cd branch-1.0
    
  2. Import to the empty trunk:
    > svn import https://your-project.googlecode.com/svn/trunk \
       -m 'Stable source from branches/1.0, revision 26.'
    

Pros: Quick and easy, without deleting the current trunk tree.
Cons: What happened on the branch (history) stays on the branch.

Got another solution? I’d love to hear from you.

jstcky: A stick or die JavaScript framework

Got a new project started at Google Code. It’s simple called “jstcky“. It’s a framework written in JavaScript and uses jQuery library that stick or fix a menu/app bar at the bottom of a page. It is inspired by Facebook’s fixed application/chat bar. Please checkout my post on how to fix an element/bar on the bottom of a page.

The project is still undergoing development. So, bugs may crawl and few functionalities as of this time.

I’ve already upload the jstcky codebase on Google Repository under “branches” tree. So do check it out!

How to remove [caption] shortcode from Add-Meta-Tags 1.6

While I was tinkering with my blog site, trying to (somehow) optimize it. I’ve noticed that the “Meta-Description” in which the Add-Meta-Tags generates, included the “[ caption ]” shortcode in the header’s meta-description, that is if I have an embedded image on my post. SEO professionals would say that “it’s a big No no!”. So, what’s a guy gotta do? Remove it! But then I still want a caption for my embedded images (on posts). So, editing every post and removing the code manually will not do.

I’d searched a fix on google but no luck. But, I’ve found one for All-In-One-SEO-Pack using regular expression to strip all shortcode. Tried it on Add-Meta-Tags and you guessed it! It worked!

Here’s how to you do it:

  1. Edit your ‘add-meta-tags.php‘ from ‘/wp-content/plugins/add-meta-tags-1.6‘ directory.
  2. Search for the function ‘amt_clean_desc
  3. Then add this code (one line before ‘return trim($desc);‘):
    $desc = preg_replace('|\[(.+?)\](.+?\[/\\1\])?|s', '', $desc);
    
  4. Save it then upload it back to the server.

That’s it!

How to share folders in Linux using samba

Have you tried sharing a folder in Linux, especially in OpenSuse? If you open your File Browser/Nautilus and you right clicked on a folder, you will see a “Sharing Options” and when you try to share a folder and hit on the “Create Share” button, there’s an error prompting at the window: ‘net usershare’ returned error 255: net usershare: usershares are currently disabled.

Well the solution to this problem is quite simple:

Note: Before starting make sure that Samba is already installed and that the Samba daemon are already started:

Starting the Samba daemon

As root:

rawswift:~ # /etc/init.d/smb start
Starting Samba SMB daemon                                            done
rawswift:~ #

Now here’s what you will do next (as root):

  1. Edit ‘/etc/samba/smb.conf’.
    rawswift:~ # vi /etc/samba/smb.conf
    

    add the following under the “[global]” category:

    usershare allow guests = Yes
    usershare max shares = 100
    usershare owner only = False
    
  2. Create the ‘usershare’ directory (this is where Samba will store the lists of shared folders).
    rawswift:~ # mkdir /var/lib/samba/usershares
    rawswift:~ # chgrp users /var/lib/samba/usershares/
    rawswift:~ # chmod 1770 /var/lib/samba/usershares/
    
  3. Then finally, restart Samba daemon:
    rawswift:~ # /etc/init.d/smb restart
    Shutting down Samba SMB daemon                                       done
    Starting Samba SMB daemon                                            done
    rawswift:~ #
    

That’s it! Simple, eh?

Share a folder

  1. Open your file browser/Nautilus.
  2. Right click the folder you want to share.
  3. Click ‘Sharing Options’.
  4. Tick ‘Share this folder’ and ‘Guest access (for people without a user account)’.
  5. And hit ‘Create Share’ button.