Monday, November 23, 2015

Mercurial Tips

  1. Trashcan - [from the docs] The shelve tool is very conservative with your source and patch files. Before it modifies any file it makes a backup under .hg/Trashcan. This trashcan can be emptied by running the purge dialog from the Workbench Repository –> Purge menu option.

Monday, October 19, 2015

You don't currently have permission to access this folder

So you mount an external disk, try to go to the directory where you need to go and Windows tells you that you don't have the permission to do that.
I never understood the philosophy of Windows security, probably because I'm used to Linux. I don't want to understand it anyway unless it gets in my way.
What I tried successfully is:
  1. Open the folder's Properties.
  2. Go to Security and click Advanced.
  3. Change Owner: Enter the object name to select and do Check Names.
  4. Check Replace owner on subcontainer and objects.
  5. Ignore the Windows security warning.
  6. You're done!

Monday, October 05, 2015

Restoring Audio Service in Windows 10

Today I couldn't listen to anything or change the volume or do anything related to audio.
Someone suggested to:

> net stop audiosrv
> net stop AudioEndpointBuilder
> net start audiosrv
> net start AudioEndpointBuilder


After 5 minutes I'm still trying to see if the first command will ever end.


I'll never find out. I finally had to reboot. I tried the put-it-to-sleep solution but it went into eternal sleep.
That's always been Windows' solution: "reboot without  saving your changes"!

Tuesday, June 02, 2015

DokuWiki Hrun Alerts About Update even When Done

"Hotfix release available" alerts keep being displayed even after you do the update.
Apparently there is a bug.
In some places they explain you can manually remove the file: data/cache/messages.txt.
For me this doesn't work since the file is recreated right away.
What I did was to empty the file and leave it there and that worked.
... for a while. Now it's there again.

More info here if you want to try something.

Thursday, May 07, 2015

Take Ownership and Assign Permissions to Yourself on Windows

Sometimes on mounted external drives, you are not the owner (don't ask me why, I'll never understand what's the reasoning behind Windows in general) and cannot change/view files.
Try this:

# Recursively take ownership of directory:
> takeown /f "c:\path"

# Reset permissions recursively
> icacls "c:\path" /reset /T

Monday, March 30, 2015

Dell Laptop: Plugged In, Not Charging

I recently noticed this unwanted message on my Dell Latitude E6540 with Windows 7.
Don't know exactly what prompted it but the battery would not charge above 64%, no matter how I changed the settings of the power saving mode.
Here's how I solved it:
  1. Power off
  2. Remove the battery
  3. Restart Windows
  4. Go to Control Panel -> Hardware and Sound -> Device Manager
  5. Under Batteries, remove all Microsoft AC Adapter and Microsoft ACPI-Compliant Control Method Battery
  6. Power off
  7. Put the battery back in place
  8. Restart Windows
Then magically the battery restarted charging and didn't stop until it reached 100%.
Thanks to nickscomputerfix!

On the contrary, a good reason not to keep it charged at 100%:

The third tip relates to when and by how much batteries should be charged. One of the more widely known aspects about battery life is the “memory effect”.
In older rechargeable battery chemistries, such as nickel cadmium, partial charging and discharging significantly decreases the energy capacity.
What is less known is that the memory effect in lithium-ion batteries, if it exists, tends to be very small. Instead, they have quite nuanced characteristics. When not in use, batteries degrade most when fully charged. So if left for several days or weeks without use, they should ideally be kept at a relatively low charging state, e.g around 20% charged.
Conversely, when being charged and discharged a lot, it is best to keep the batteries as close to the 50% mark as possible. So if you are only charging and discharging batteries a bit at a time, it is much better to do this between 45-55% than between 90-100%.

Full article.

Thursday, February 05, 2015

Windows Taskbar Does Not Hide

Sometimes even if you configured the taskbar to hide itself, it won't and you tried everything you know.
Welcome to the Windows way of doing things!
There is probably a notification from some process, which you cannot easily spot.
The quick way to solve this: kill and restart the file explorer.

Go to the Task Manager --> Processes, and kill explorer.exe.
Then File --> New Task (Run) and type explorer.exe.
Done!

Monday, January 12, 2015

iReport 5.6.0 Failing Silently

Versions up to 5.6.0 (currently the last one) do not run with JDK 1.8. They will silently fail, at least on Windows 7.
If you want to keep JAVA_HOME set to a JDK 1.8 installation, you can run it launching a batch file with something like this inside:

@echo off
set JAVA_HOME=C:\opt\java\jre1.7.0_71
"C:\Program Files (x86)\Jaspersoft\iReport-5.6.0\bin\ireport.exe"

Customize as needed.