Posts Tagged ‘save’

Remember screen brightness settings in Ubuntu and Linux Mint

Monday, October 29, 2012 posted by CSch

Screen brightness is an attribute that is reset automatically upon rebooting your machine on Ubuntu and all its fellow distributions. Lucky you if you find the settings okay, but on notebooks and similar machines, you might want to lower the brightness, you it doesn't suck your batteries dry.

To do that, open the following file as root via terminal:

sudo gedit /etc/rc.local

In there, enter the following line somewhere before the very last one that says "exit 0":

echo 0 > /sys/class/backlight/acpi_video0/brightness

0 is the lowest brightness setting. You can adjust it to your likings!

Windows 7 comes with the Aero skin by default which might look nice but consumes a great deal of resources - and with them, power. I have experienced a loss of up to two hours of battery life on my notebook when turning Aero on which one can get back by switching to the classic skin - that ugly gray one, that was used in the times before Windows XP.

It would be great if Windows provided an option to set a scheduled task to trigger on plugging or unplugging the power supply or to configure the power settings to change themes automatically but unfortunately we don't have that luxury, so we have to do it ourselves, in a slightly less elegant way.

What you need is a small VBScript which you can find here and a PowerShell script which checks in what state the notebook battery is in. To create that script, open a new notepad and paste the following into it:

$sav = (Get-WmiObject -Class Win32_Battery -ea 0).BatteryStatus
while ($true)
{
start-sleep -s 5
if (((Get-WmiObject -Class Win32_Battery -ea 0).BatteryStatus -eq (1 -or 3 -or 4 -or 5 -or 10 -or 11)) -and ((Get-WmiObject -Class Win32_Battery -ea 0).BatteryStatus -ne $sav))
{
& 'C:\Windows\Resources\Ease of Access Themes\Classic.theme'
$sav = (Get-WmiObject -Class Win32_Battery -ea 0).BatteryStatus
}
else
{
if ((Get-WmiObject -Class Win32_Battery -ea 0).BatteryStatus -ne $sav)
{
& 'C:\Windows\Resources\Themes\Aero.theme'
$sav = (Get-WmiObject -Class Win32_Battery -ea 0).BatteryStatus
}}}

Adjust the paths printed bold to the location of the themes you want to use if you want different ones (the first one is the one that is applied on unplugging the supply, second is for replugging). Save the script as a .ps1 file. If you haven't yet created the VBScript, do it now following the above link. Remember to adjust the path to the ps1 script used there to yours. If you now launch the VBScript the PowerShell script should be started silently. If you get an error or the script won't start, you first have to configure your system to allow executing PowerShell scripts - see the instructions below the code provided here.

The locations of the themes are
C:\Windows\Resources\Ease of Access Themes for the classic styled themes.
C:\Windows\Resources\Themes for preconfigured Aero style themes and
C:\Users\[YourUsername]\AppData\Local\Microsoft\Windows\Themes for custom themes (the AppData folder is hidden by default).

To automate everything you can set the execution of your VBScript as a scheduled task. Do so by entering Task Scheduler into your Start-menu search bar. Set up the task for execution on start up if you want it to be run on every session.

Undelete Deleted Files with Recuva on Windows 7

Thursday, February 9, 2012 posted by CSch

Apart from CCleaner, Piriform has released some other useful pieces of software. Among them is Recuva, a tool to save and undelete removed data.

Files you delete are not physically removed from your hard drive until they are overwritten by new data, which makes it possible to retrieve them as long as nothing new is written on their clusters - this also includes removing data or wiping hard drives with special software such as CCleaner since they take care of deleting data properly by overwriting their hard disk space (this method is used to make deleted data inaccesible).

After checking for deleted files, make sure to go through the list for your wanted files carefully since their filenames may have changed like in the screenshot above.

You can download Recuva here: http://www.piriform.com/recuva
Like for CCleaner, there is also a portable version: http://www.piriform.com/recuva/features/portable-version

Save Power On Screen Lock (Windows 7)

Wednesday, November 23, 2011 posted by CSch

The reason to lock your screen (Windows key + L) usually is that you leave your computer, meaning it would be reasonable to turn off everything else there is on your computer as the sound or your screen as well. MonitorES is a utility that does this for you whenever you lock your screen.

It turns off the screen, mutes your computer, pauses any media playing and changes your IM status to "Away" if you want it. Download it on http://code.google.com/p/monitores/

Save Tabs on Current Firefox Version

Thursday, November 10, 2011 posted by CSch

From version 4 on, FireFox has disabled the option to save tabs when you leave the browser and left us with the Restore Session option on program start. To enable the option to save tabs again, direct FireFox to about:config and accept the prompt. In the filter bar, enter browser.showquitwarning and double-click the value to toggle it to true. Firefox will now ask you if you want to save your tabs again: