Search Results

Search found 12 results on 1 pages for 'jonatan littke'.

Page 1/1 | 1 

  • MouseTerm and Terminal.app

    - by Jonatan Littke
    Hey. I'm trying to get MouseTerm to work with Terminal.app. I'm on Snow Leopard and followed the install instructions promptly (which are, simply, download the .dmg and run the 'Install' file). When I start Terminal.app, I still can't use the mouse (specifically in Vim, using set mouse=a). Anyone got it working?

    Read the article

  • Vim and mouse with ssh from Mac to Linux

    - by Jonatan Littke
    Hey. I certainly know it's possible to make the mouse work in Vim on a remote session to a Linux machine from my Mac, but I haven't figured out just how. Daily vim gives a tip on making it work but if I try to set 'mac-ansi', for example, I get an error saying I can only specify values beginning with builtin_ (riscos, beos-ansi, etc). I've tried using ssh -X, combined with set mouse=a and set term=builtin_anso for example, but with no success with or without combining them. I'm using Snow Leopard and attempting to use the mouse on a Debian machine with vim 7.1.314. I've had a look at the documentation but can't make it work. Any tips?

    Read the article

  • Millions of files in php's tmp error - how to delete?

    - by Jonatan Littke
    Hey. I've got a tmp-folder with 14 million php session files in my home directory. At least that's what I think it is, it's not like I could ls it or anything. How can I empty this folder? I've tried using find with the -exec rm {} \; commands but that didn't work. ls 'sess_0*' | xargs rm did neither. I'm currently running rm -rf tmp but after two hours the folder appears to be the same size. REFERENCE INFO: I suddenly encountered an error where SESSIONS could no longer be written to disk: [Mon Apr 19 19:58:32 2010] [warn] mod_fcgid: stderr: PHP Warning: Unknown: open(/var/www/clients/client1/web1/tmp/sess_8e12742b62aa68a3f9476ec80222bbfb, O_RDWR) failed: No space left on device (28) in Unknown on line 0 [Mon Apr 19 19:58:32 2010] [warn] mod_fcgid: stderr: PHP Warning: Unknown: Failed to write session data (files). Please verify that the current setting of session.save_path is correct (/var/www/clients/client1/web1/tmp) in Unknown on line 0 I ran: $ df -h Filesystem Size Used Avail Use% Mounted on /dev/md0 457G 126G 308G 29% / tmpfs 1.8G 0 1.8G 0% /lib/init/rw udev 10M 664K 9.4M 7% /dev tmpfs 1.8G 0 1.8G 0% /dev/shm But as you can see, the disk isn't full. So I had a look in the syslog which says the following 20 times per second: kernel: [19570794.361241] EXT3-fs warning (device md0): ext3_dx_add_entry: Directory index full! This led me thinking to a full folder, obviously, but since my web folder only has 60k files (having counted them), I guessed it was the tmp folder (the local one, for this instance of php) that messed things up. Some commands I ran: $ sudo ls sess_a* | xargs rm -f bash: /usr/bin/sudo: Argument list too long find . -exec rm {} \; rm: cannot remove directory '.' find: cannot fork: Cannot allocate memory I'm running Debian Lenny, php5, ISPConfig, SuEXEC and Fast-CGI.

    Read the article

  • Aliased network interfaces and isc dhcp server

    - by Jonatan
    I have been banging my head on this for a long time now. There are many discussions on the net about this and similar problems, but none of the solutions seems to work for me. I have a Debian server with two ethernet network interfaces. One of them is connected to internet, while the other is connected to my LAN. The LAN network is 10.11.100.0 (netmask 255.255.255.0). We have some custom hardware that use network 10.4.1.0 (netmask 255.255.255.0) and we can't change that. But we need all hosts on 10.11.100.0 to be able to connect to devices on 10.4.1.0. So I added an alias for the LAN network interface so that the Debian server acts as a gateway between 10.11.100.0 and 10.4.1.0. But then the dhcp server stopped working. The log says: No subnet declaration for eth1:0 (no IPv4 addresses). ** Ignoring requests on eth1:0. If this is not what you want, please write a subnet declaration in your dhcpd.conf file for the network segment to which interface eth1:1 is attached. ** No subnet declaration for eth1:1 (no IPv4 addresses). ** Ignoring requests on eth1:1. If this is not what you want, please write a subnet declaration in your dhcpd.conf file for the network segment to which interface eth1:1 is attached. ** I had another server before, also running Debian but with the older dhcp3 server, and it worked without any problems. I've tried everything I can think of in dhcpd.conf etc, and I've also compared with the working configuration in the old server. The dhcp server need only handle devices on 10.11.100.0. Any hints? Here's all relevant config files: /etc/default/isc-dhcp-server INTERFACES="eth1" /etc/network/interfaces (I've left out eth0, that connects to the Internet, since there is no problem with that.) auto eth1:0 iface eth1:0 inet static address 10.11.100.202 netmask 255.255.255.0 auto eth1:1 iface eth1:1 inet static address 10.4.1.248 netmask 255.255.255.0 /etc/dhcp/dhcpd.conf ddns-update-style none; option domain-name "???.com"; option domain-name-servers ?.?.?.?; default-lease-time 86400; max-lease-time 604800; authorative; subnet 10.11.100.0 netmask 255.255.255.0 { option subnet-mask 255.255.255.0; pool { range 10.11.100.50 10.11.100.99; } option routers 10.11.100.102; } I have tried to add shared-network etc, but didn't manage to get that to work. I get the same error message no matter what...

    Read the article

  • Making libmagic/file detect .docx files

    - by Jonatan Littke
    As seen elsewhere, docx, xlsx and pttx are ZIPs. When uploading them to my web application, file (via libmagic andpython-magic) detects them as being ZIP. I store the contents of the file as a blob in the database, but naturally I don't want to trust the user with what kind of file type this is. So I would like to trust file for and automatically generate a filename during download. I know one can modify /etc/magic but the format (magic(5)) is way too complicated for me. I found a bug report on the issue at Debian bugs but since it's from 2008 it doesn't seem to be fixed any time soon. I guess my only other alternative is to indeed trust the user (but still store the contents as a blob) and only check the file extension based on the file name. This way I can disallow some extensions and allow others. And when the user re-downloads his file, he can have it in whatever way he uploaded it. But this solution is insecure if the file is shared with others, since you can simply rename the file to allow uploading it. Any ideas? Lastly, I found a list of magic numbers for docx etc, but I'm unable to convert these into the magic(5) format.

    Read the article

  • MacVim and netrw - Press ENTER

    - by Jonatan Littke
    Hey guys. I've set up MacVim to work with netrw for remote editing (yaaay!), but whenever I save a file, I get the following error: :!scp -q '/var/folders/PN/PNhWJAr5GGC0WfeLdFgWV++++TU/-Tmp-/v771493/0' 'remot_host:path/remote_file.css' Press ENTER or type command to continue Hitting ENTER removes it and I can edit again. I don't know what it is and it's annoying, but perhaps not broken. Tips?

    Read the article

  • Changing a form's action attribute in IE?

    - by Jonatan Littke
    Hey. I'm trying to set a hash value in a form's action, to keep it when the form is submitted. Firefox allows me to update the hash and redirects accordingly, but IE doesn't. I initially thought this was related to IE not allowing hash values in the action attribute at all, but it seems I can't dynamically set the action at all in IE - with a hash or not? Is that right? I'm using the following jQuery: $("#options-form").attr('action', '#' + hash); To update: <form id="options-form" action="" method="get"> (On a sidenote, this wasn't needed in Firefox, because FF appears to preserve the current hash if it was only the GET params that changed.)

    Read the article

  • GNU ld removes section

    - by Jonatan
    I'm writing a boot script for an ARM-Cortex M3 based device. If I compile the assembler boot script and the C application code and then combine the object files and transfer them to my device everything works. However, if I use ar to create an archive (libboot.a) and combine that archive with the C application there is a problem: I've put the boot code in a section: .section .boot, "ax" .global _start _start: .word 0x10000800 /* Initial stack pointer (FIXME!) */ .word start .word nmi_handler .word hard_fault_handler ... etc ... I've found that ld strips this from the final binary (the section "boot" is not available). This is quite natural as there is no dependency on it that ld knows about, but it causes the device to not boot correctly. So my question is: what is the best way to force this code to be included?

    Read the article

  • wxGraphicsContext dreadfully slow on Windows

    - by Jonatan
    I've implemented a plotter using wxGraphicsContext. The development was done using wxGTK, and the graphics was very fast. Then I switched to Windows (XP) using wxWidgets 2.9.0. And the same code is extremely slow. It takes about 350 ms to render a frame. Since the user is able to drag the plotter with the mouse to navigate it feels very sluggish with such a slow update rate. I've tried to implement some parts using wxDC and benchmarked the difference. With wxDC the code runs just about 100 times faster. As far as I know both Cairo and GDI+ are implemented in software at this point, so there's no real reason Cairo should be so much faster than GDI+. Am I doing something wrong? Or is the GDI+ implementation just not up on par with Cairo? One small note: I'm rendering to a wxBitmap now, with the wxGraphicsContext created from a wxMemoryDC. This is to avoid flicker on XP, since double buffering doesn't work there.

    Read the article

  • Vim: Pasting from clipboard and automatically toggling :set paste

    - by Jonatan Littke
    Hey. When I paste things from the clipboard, they're normally (always) multilined, and in those cases (and those cases only), I'd like :set paste to be triggered, since otherwise the tabbing will increase with each line (you've all seen it!). Though the problem with :set paste is that it doesn't behave well with set smartindent, causing the cursor to jump to the beginning of a new line instead of at the correct indent. So I'd like to enable it for this instance only. I'm using Mac, sshing to a Debian machine with vim, and thus pasting in Insert mode using cmd-v. Cheers.

    Read the article

  • How to pass a link to Facebook iPhone app status update?

    - by Jonatan
    It's possible to create href-attibutes that makes the iPhone quit Safari and launch another app. For the official Twitter-app this would look like: <a href="twitter:///post?message=my+important+message">Click to deliver message to Twitter-apps status updater</a> For the Facebook-app the protocoll is: fb:/// But i can't figure out, or find any information about, how to get my message (a url to share) directly into the the status updater. Is there a url-scheme, or am I going about this the wrong way?

    Read the article

  • Get expiration time of a memcache item in php?

    - by Jonatan Littke
    Hey. I'm caching tweets on my site (with 30 min expiration time). When the cache is empty, the first user to find out will repopulate it. However, at that time the Twitter API may return a 200. In that case I'd like to prolong the previous data for another 30 mins. But the previous data will already be lost. So instead I'd like to look into repopulating the cache, say, 5 minutes before expiration time so that I don't lose any date. So how do I know the expiration time of an item when using php's memcache::get()? Also, is there a better way of doing this?

    Read the article

1