Sunday, October 16, 2011

OpenERP Web Not Starting

If you have accidentally replacee CherryPy3 with CherryPy you will get the following error when starting openerp-web
AttributeError: 'module' object has no attribute 'Tool'
Just reinstall CherryPy3 to get back a working installation

Sunday, December 10, 2006

Vertical Split for GNU Screen

This patch provides a vertical split feature for current releases of GNU Screen. The feature is designed to function in the same manner as screen's existing split command, but dividing the regions vertically instead of horizontally. Both forms of splits can be used together in any combination/quantity/order desired. Direct link: bz2

Resume EMERGE after interruption

  • ebuild /usr/portage/package category/package name/.ebuild file install
  • ebuild /usr/portage/package category/package name/.ebuild file qmerge
  • ebuild /usr/portage/package category/package name/.ebuild file clean

Monday, July 31, 2006

Readline (bash) shortcuts

Only the ones I forget frequently:
* Tab Tab  Only Sub Dirs inside without Hidden one
$ Tab Tab  All Sys variables
@ Tab Tab  Entries from "/etc/hosts"
= Tab Tab  Output like ls or dir
Ctrl + a  Jump to the start of the line
Ctrl + b  Move back a char
Ctrl + e  Jump to the end of the line
Ctrl + f  Move forward a char
Ctrl + k  Cut to EOL
Ctrl + r  Search the history backwards
Ctrl + R  Search the history backwards with multi occurrence
Ctrl + u  Delete backward from cursor
Ctrl + w  Delete token left of cursor
Ctrl + xx  Move between EOL and current cursor position
Ctrl + y  Paste to EOL
Alt + >  Move to the last line in the history
Alt + *  Insert all possible completions
Alt + n  Search the history forwards non-incremental
Alt + p  Search the history backwards non-incremental
Alt + r  Recall command
Alt + back-space  Delete word left of cursor

Saturday, July 29, 2006

xmodmap revisited (Winkey, Intellimouse)

Wheel scrolling
xmodmap -e "pointer = 1 2 3 6 7 4 5"

xmodmaprc:

keycode 115 = Super_L
add mod4 = Super_L
keycode 116 = Super_R
add mod4 = Super_R

Thursday, June 22, 2006

Firefox+Keyconfig: Focus tab/window content

Focus Content Activate the selected content, as if you clicked on it. You need this, for example, if you want to scroll with the cursor keys and nothing happens (yeah, it happens a lot ;) ). user_pref("keyconfig.main.xxx_key__Focus Content", "!][][][_content.focus();");

Friday, May 26, 2006

Printable Forms with Javascript

<html> <head> <style type="text/css" media="print"> textarea {border:0;} </style> <script> function countLines(obj){ //count number of lines entered return obj.value.match(new RegExp("(\\n)","g")).length; } function doPrint(){ txta = document.getElementById("ta"); //expand textarea according to entered text txta.rows=countLines(txta); window.print(); } </script> </head> <body> <input type="button" text="Print" onclick="doPrint()"> <form> <textarea id="ta" cols="80" rows="2">Some text with line breaks some more texts</textarea> </form> </body> </html>

Friday, May 19, 2006

How to Deploy ASP.NET 2.0 Web Site Administration Tool (WAT) on Production Servers

Create a virtual directory ASP.NETWebAdminFiles in IIS that point to C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\ASP.NETWebAdminFiles Open properties windows of the new virtual directory, make sure that it is configured to run with ASP.NET 2.0, and in Security tab, uncheck Anonymous Access, check Integrated Windows Authentication. After that, you will be able to connect to WebAdminTools using the following syntax http://localhost/ASP.NETWebAdminFiles/default.aspx?applicationPhysicalPath=XXX&applicationUrl=/YYY in my case, it is: http://localhost/ASP.NETWebAdminFiles/default.aspx?applicationPhysicalPath=D:\Tasks\Libranyon\Photonyon\&applicationUrl=/Photonyon Although I don't recommend to do it, if you want to access WebAdminTool from other computer, open WebAdminPage.cs from (C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\ASP.NETWebAdminFiles\App_Code) and comment the following code block
if (!application.Context.Request.IsLocal) { SecurityException securityException = new SecurityException( (string)HttpContext.GetGlobalResourceObject('GlobalResources', 'WebAdmin_ConfigurationIsLocalOnly')); WebAdminPage.SetCurrentException(application.Context, securityException); application.Server.Transfer('~/error.aspx'); }