All posts strictly related to Ubuntu.

Packagekit with apturl

Caveat lector: I wrote this post in high school; it’s likely outdated and poorly written.

Although I no longer use packagekit, I still have my apturl script so I thought I would post it. This script will allow you to open apt:// scripts with packagekit. (Just save this to a file, mark it executable, and tell your browser to open apt scripts with it).

#!/bin/bash
/usr/bin/gpk-install-package-name $(echo $* | sed -e 's/apt:\/\?\/\?//')

Service Manager for Karmic

> Caveat lector: I wrote this post in high school; it’s likely outdated and poorly written.

Annoyingly, as karmic has mostly switched to Upstart, it does not include a service manager. While I hope that the gnome service-manager will be updated to include support for upstart soon I have, for the interim, written a very simple service manager.

Be warned: When I say “very simple” I mean “very simple, noob unfriendly, and potentially dangerous”. While it should not harm your computer, I make no guarantees because it is my first PyGTK program and was written in my spare time over a couple of days. A word of warning, the code is very messy and inefficient (understatement).

Link

Apt Repository Permissions

Caveat lector: I wrote this post in high school; it’s likely outdated and poorly written.

I just posted a solution to this idea but thought that I should share it here.

Here is the problem: In order to get the latest features on Ubuntu, people are adding a lot of PPAs. For now there hasn’t, as far as I know, been a case in which a PPA owner has uploaded a malicious package but this is a possibility. Uploading an end user application, such as shutter, with malicious code would be problematic but not devastating. On the other hand, uploading a malicious sudo package would be devastating. Here is my solution.

Different repositories would “own” packages:

  1. Ownership would be set in a file such as /etc/apt/ownership/.list
  2. A special system packages file would be created that would designate system packages (sudo, pam etc…).

Apt repositories would have permissions:

  1. Ultimate Trust: Update and Install packages from this repository regardless of ownership including system packages.
  2. All: Update and Install new packages from this repository regardless of ownership (except system owned packages).
  3. Owned only: Update and install only owned packages.
  4. No Updates: Install owned packages from this repository but do not download updates from it.

Flags:

  1. Warning: There would be a warning flag that a user could set on a repository that would warn when packages are updated or installed from that repository.
  2. System: There would be a system flag that could be set on security related packages (sudo, bash etc…) that would prevent all but “Ultimate Trust” repositories from installing/updating them.

How to invite someone to Ubuntu One

Caveat lector: I wrote this post in high school; it’s likely outdated and poorly written.

For anyone with an Ubuntu One account, the following are instructions for sending invites:

  1. Go to My Files in the web interface.
  2. Create a new folder (to be shared) with the person that you will be inviting
  3. Go to the sharing tab (on the right).
  4. Share the folder with the person that you want to invite (The trick is that someone does not have to have an Ubuntu One account to accept a share).

http://ubuntuone.com

For anyone looking for an invite, just ask @bugabundo at Identi.ca.

Running the "Ubunu System Panel" on a 64 bit machine.

Caveat lector: I wrote this post in high school; it’s likely outdated and poorly written.

After installing the 64 bit version of Ubuntu on my Dell Inspiron 1420n I found that the USP (Ubuntu System Panel) keybindings do not work. This is because the /usr/lib/python2.4/site-packages/usp/plugins/_keybinder.so is compiled for a 32 bit system. After a little searching I found out that Glipper includes a _keybinder.so file. After replacing USP’s _keybinder.so with Glipper’s version, the keybindings worked fine.

  1. Download glipper aptitude download glipper.
  2. Extract the glipper deb with dpkg-deb -x glipper_1.0-1ubuntu1_amd64.deb glipper (change glipper_1.0-1ubuntu1_amd64.deb to the name of your file).
  3. Copy in the new _keybinder.so with sudo cp ./glipper/usr/lib/python-support/glipper/python2.5/glipper/keybinder/_keybinder.so /usr/lib/python2.4/site-packages/usp/plugins/_keybinder.so.
  4. Restart USP with killall gnome-panel and your USP shortcut keys should now work.

Edit: This is no longer necessary.

Tip: Purge Auto-installed packages with Aptitude

Caveat lector: I wrote this post in high school; it’s likely outdated and poorly written.

When switching from apt-get to aptitude, I discovered that aptitude, unlike apt-get, does not purge configuration files of auto-removed packages when given the command aptitude purge package. The fix for this is very simple.

In order to purge configuration files only when the purge command is given you must either specify the --purge-unused option in the command or create an alias. To create an alias add this alias command='sudo aptitude purge --purge-unused' to ~/.bashrc. Command is the command that you would like to assign for purging the packages.

To always purge configuration files for auto-removed packages add Aptitude::Purge-Unused=true to /etc/apt/apt.conf.d/05aptitude. This will cause aptitude to always purge configuration files for all auto-removed packages regardless of weather or not the command was aptitude purge or aptitude remove.

Ubuntu hardy upgrade status: Buggy but working

Caveat lector: I wrote this post in high school; it’s likely outdated and poorly written.

I ran into a few problems during the upgrade but all of them were fixable.

Partial Upgrade fix: Downgrade non-ubuntu packages to their ubuntu versions if an ubuntu version exists. My system refused to complete the upgrade (and I had to upgrade it through aptitude) because of a few package conflicts (mostly from the schmidtke repository).

Numpad Fix: My computers numpad stopped working after upgrading. Somehow an acceptability option had been turned on. To fix this go to System > Preferences > Keyboard and go to the mouse keys tab and uncheck the checkbox.

Remove custom G15 drivers: A while back I had installed the G15 drivers based on a tutorial posted on the ubuntu wiki. These drivers should now be uninstalled as Ubuntu Hardy comes with its own drivers.

Everything appears to be working fine now.

Tip: Faster Ubuntu upgrade

Caveat lector: I wrote this post in high school; it’s likely outdated and poorly written.

I am currently upgrading to Ubuntu 8.04 and so far so good. For the past releases I have upgraded from the standard server but that was very slow (8 hour download).

Fix: Use another server.

My current download is almost complete and my download speed is currently at 164kb/s (my max, thanks AT). To change the download server, simply open System > Administration > Software Sources and select download from other. Pick a random server in your country and hope for the best (the pick the best server button does not find the least bogged down server, it finds the closest server). The Ubuntu teem should make this happen automatically. The System Updater should find the mirror with the greatest download speed and use that server for its upgrade.

Gnome-Blog debs

Caveat lector: I wrote this post in high school; it’s likely outdated and poorly written.

I have just uploaded the patched gnome-blog deb and an updated python-gdata deb (gnome-blog requires python-gdata 1.0.1 or up but gutsy only includes 1.0). The python-gdata is unnecessary if you use hardy but is a later version than the one provided by hardy.

My PPA:

deb http://ppa.launchpad.net/stebalien/ubuntu gutsy main
deb-src http://ppa.launchpad.net/stebalien/ubuntu gutsy main

Edit: I got the patch from http://bugzilla.gnome.org/show_bug.cgi?id=151291 (thanks to Richard Schwarting)