Search Results

Search found 23 results on 1 pages for 'itsadok'.

Page 1/1 | 1 

  • Alt-Tab in Unity 2D makes app icon jiggle instead of switching

    - by itsadok
    I'm using Unity 2D as my desktop, and it works fine most of the time, but every now and then, I try to Alt-Tab to switch to a different application, and instead of switching to that window, the launcher bar opens, and the icon of the application I was trying to switch to starts jiggling. If I try to switch to something else, that icon starts jiggling too. If I click on the icon with the mouse, then it stops jiggling and switches to the requested window. What is this behavior? I haven't seen any mention of jiggling icons in Unity. I don't understand the original purpose of this, and I'd like a way to fix it so that I won't have to use the mouse.

    Read the article

  • How could there still not be a mysqldb module for Python 3?

    - by itsadok
    This SO question is now more than two years old. MySQL is an incredibly popular database engine, Python is an incredibly popular programming language, and Python 3 has been officially released two years ago, and was available even before that. What's more, the whole mysqldb module is just a layer translating Python's db-api to MySQL's API. It's not that big of a library. I must be missing something here. How come almost* nobody in the entire open source community has spent the (I'm guessing) two weeks it takes to port this lib? Is Python 3 that unpopular? Is the combination of python and mysql not as common as I assume? Or maybe it's just a lot harder to port mysqldb than I assume? Anyone know the inside story on this? * Now I see that this guy has done it, which takes some of the wind out of my question, but it still seems to little and too late to make sense.

    Read the article

  • Stupid simple music player?

    - by itsadok
    Here's what I want: I have a folder with MP3 files. I would like to play all the files in the folder, alphabetically. And I need a way to pause, skip to next file, and that's pretty much it. I don't want to use my music player to organize my music library, I don't need connection to network services, and I don't even need ID3 support. On Windows, WinAmp 2 did what I wanted. What's my best option on Ubuntu?

    Read the article

  • How could there still not be a mysqldb module for Python 3? [closed]

    - by itsadok
    This SO question is now more than two years old. MySQL is an incredibly popular database engine, Python is an incredibly popular programming language, and Python 3 has been officially released two years ago, and was available even before that. What's more, the whole mysqldb module is just a layer translating Python's db-api to MySQL's API. It's not that big of a library. I must be missing something here. How come almost* nobody in the entire open source community has spent the (I'm guessing) two weeks it takes to port this lib? Is Python 3 that unpopular? Is the combination of python and mysql not as common as I assume? Or maybe it's just a lot harder to port mysqldb than I assume? Anyone know the inside story on this? * Now I see that this guy has done it, which takes some of the wind out of my question, but it still seems to little and too late to make sense. EDIT: OK, I'm aware that the stock answers for these kind of questions cover this one as well. Patches welcome, scratch your itch, we don't work for you and we don't have the time, etc. I actually took a shot at porting this about a year ago, but it was my first time doing anything with Python C extensions, and I failed. My point in writing this was not a plea for somebody to write it, but genuine curiosity: it seems that some much more complicated libraries have been ported to python 3 already, and in the poll for which libraries should be ported, mysqldb is not even nominated! That suggests that maybe (2) is the right answer. UPDATE: I found that there are several new libraries that provide mysql support under Python 3, I just wasn't googling hard enough. That explains everything.

    Read the article

  • Can I configure a DNS cache not to forward AAAA queries?

    - by itsadok
    I'm setting up an internal DNS cache because my firewall is having trouble handling all the sessions created by DNS requests. I tried using bind9, dnsmasq and DJB dnscache, they all help reduce the number of requests leaving my network, but there are still a lot of request being made. Looking at the log files, and tcpdump and dnstop outputs, it seems that requests that return SERVFAIL do not get cached at all. And a lot of those failed requests are AAAA requests, which is a shame, because I do not have ipv6 enabled on any server. I've looked at several ways to help the situation, and I think if I could somehow prevent AAAA record requests from being forwarded by the DNS cache, it would reduce the number of requests significantly. The closest thing I found was the filter-aaaa-on-v4 option in BIND9. However, this only removes the record from the server response, and does not prevent it from forwarding it. Any help would be appreciated.

    Read the article

  • How to keep haproxy log messages out of /var/log/syslog

    - by itsadok
    I set up haproxy logging via rsyslogd using the tips from this article, and everything seems to be working fine. The log files get the log messages. However, every log message from haproxy also shows up at /var/log/syslog. This means that once the server goes live, the syslog will be quite useless, as it will be run over with haproxy log messages. I would like to filter out those messages from /var/log/syslog. After going over the rsyslogd documentation, I tried to change the file /etc/rsyslog.d/50-default.conf thus: *.*;auth,authpriv.none;haproxy.none -/var/log/syslog I simply added the ;haproxy.nonepart. After restarting rsyslogd it stopped working completely until I reverted my changes. What am I doing wrong?

    Read the article

  • Strategy to allow emergency access to colocation crew

    - by itsadok
    I'm setting up a server at a new colocation center half way around the world. They installed the OS for me and sent me the root password, so there's obviously a great amount of trust in them. However, I'm pretty sure I don't want them to have my root password on a regular basis. And anyway, I intend to only allow key-based login. On some cases, though, it might be useful to let their technical support log in through a physical terminal. For example, if I somehow mess up the firewall settings. Should I even bother worrying about that? Should I set up a sudoer account with a one-time password that will change if I ever use it? Is there a common strategy for handling something like this?

    Read the article

  • Download JDK onto a remote server

    - by itsadok
    I want to get the latest JDK onto a server in a remote location. Downloading the JDK from Sun's website requires jumping through all kinds of hoops until you actually get the file. I'm not sure exactly if they use cookies or my IP address, but simply copying the file URL and trying wget on the server doesn't work. Googling for mirrors of the JDK, I could only find old versions. Right now I'm left with the option of downloading it into my computer, then uploading it to the server. This feels slow and stupid. Anyone got a better idea? EDIT: Thanks for all the replies. Just to clarify, as I'm writing this I'm rsyncing the 78MB file to my server. It should be done in about an hour, so it's not such a big deal. However, since this is not the first time I'm doing this, I was hoping for a better solution for next time. Solution: What I ended up doing was sudo aptitude install lynx-cur www-browser http://java.sun.com/javase/downloads/ From there it's mostly using the arrow and enter keys, and answering "Yes" to a lot of lynx security questions (about cookies and certificates). Thanks to resonator.

    Read the article

  • How to get a good clean newspaper scan?

    - by itsadok
    I tried a few times to scan newspaper articles, but the images I got were always blotchy and with bad colors (sort of like this). Sometimes I see some really good scans, like this. What is the trick to get such good results? Do I need some high-quality scanner, or do I need some good photoshop filters? If there was something I could do using free tools it would be awesome.

    Read the article

  • How do you kill a process tree in linux?

    - by itsadok
    Sometimes, sending a SIGTERM to a process will cause it to send SIGTERM to all its child processes. However, sometimes this doesn't work. Is there a command or a utility that will allow me to kill a process and all its child processes at the same time? I usually resort to manually collecting all the pids into one kill command, but it feels stupid. This SO question asks how to do this with perl, but anything that gets the job done would be great.

    Read the article

  • Mounting both /dev/sda and /dev/sda1 - how can this be?

    - by itsadok
    I work on an Amazon EC2 instance that somebody else set up. We have an EBS volume mounted on /dev/sda, even though the root device is already on /dev/sda1, and we're also using `/dev/sda2' user@server:~$ mount /dev/sda1 on / type ext3 (rw) ... (snip) /dev/sda2 on /mnt type ext3 (rw) /dev/sda on /vol type xfs (rw,noatime) ... This doesn't seem to fit with what I know about the way /dev/ works. How is this possible, and more importantly: will this cause trouble in the future? I'm running ubuntu 9.04 jaunty.

    Read the article

  • Spring JdbcTemplate - Insert blob and return generated key

    - by itsadok
    From the Spring JDBC documentation, I know how to insert a blob using JdbcTemplate final File blobIn = new File("spring2004.jpg"); final InputStream blobIs = new FileInputStream(blobIn); jdbcTemplate.execute( "INSERT INTO lob_table (id, a_blob) VALUES (?, ?)", new AbstractLobCreatingPreparedStatementCallback(lobhandler) { protected void setValues(PreparedStatement ps, LobCreator lobCreator) throws SQLException { ps.setLong(1, 1L); lobCreator.setBlobAsBinaryStream(ps, 2, blobIs, (int)blobIn.length()); } } ); blobIs.close(); And also how to retrieve the generated key of a newly inserted row: KeyHolder keyHolder = new GeneratedKeyHolder(); jdbcTemplate.update( new PreparedStatementCreator() { public PreparedStatement createPreparedStatement(Connection connection) throws SQLException { PreparedStatement ps = connection.prepareStatement(INSERT_SQL, new String[] {"id"}); ps.setString(1, name); return ps; } }, keyHolder); // keyHolder.getKey() now contains the generated key Is there a way I could combine the two?

    Read the article

  • JAMES Mailet development process

    - by itsadok
    I'm starting a project that involves writing mailets for Apache James. As far as I can tell, the only way to test a change in my code (on Windows) is through the following steps: Compile the mailet code Build a jar file containing the mailet Copy the jar file into the apps/james/SAR-INF/lib directory Start JAMES from run.bat Run test Stop JAMES by telneting to port 4555 and issuing a shutdown command (I guess on Linux a SIGTERM would suffice) I can automate all these steps using Ant and some scripting magic, but I was wondering if I was missing something. Does anyone here have experience developing mailets? Did you use a similar process, or is there an easier way? For example, is there a way to make a running James instance reload the mailets JAR?

    Read the article

  • Why is my spawned process still causing IntelliJ to wait?

    - by itsadok
    I'm trying to start a server as part of an Ant artifact. Here are the relevant lines: <exec dir="." executable="cmd.exe" spawn="true"> <arg line="/c c:\Java\james-2.3.2\bin\debug.bat" /> </exec> If I start it with ant from the command line, a process is spawned and I get a command prompt and everything seems fine. However, if I start it from IntelliJ 6, my IDE, the build stays alive until I kill the server. Here's the line IntelliJ uses to start ant: C:\Java\jdk1.6.0_02\bin\java -Xmx128m -Dant.home=C:\Java\apache-ant-1.7.1 -Dfile.encoding=UTF-8 -classpath "C:\Java\apache-ant-1.7.1\lib\ant-antlr.jar;C:\Java\apache-ant-1.7.1\lib\ant-apache-bcel.jar;C:\Java\apache-ant-1.7.1\lib\ant-apache-bsf.jar;C:\Java\apache-ant-1.7.1\lib\ant-apache-log4j.jar;C:\Java\apache-ant-1.7.1\lib\ant-apache-oro.jar;C:\Java\apache-ant-1.7.1\lib\ant-apache-regexp.jar;C:\Java\apache-ant-1.7.1\lib\ant-apache-resolver.jar;C:\Java\apache-ant-1.7.1\lib\ant-commons-logging.jar;C:\Java\apache-ant-1.7.1\lib\ant-commons-net.jar;C:\Java\apache-ant-1.7.1\lib\ant-jai.jar;C:\Java\apache-ant-1.7.1\lib\ant-javamail.jar;C:\Java\apache-ant-1.7.1\lib\ant-jdepend.jar;C:\Java\apache-ant-1.7.1\lib\ant-jmf.jar;C:\Java\apache-ant-1.7.1\lib\ant-jsch.jar;C:\Java\apache-ant-1.7.1\lib\ant-junit.jar;C:\Java\apache-ant-1.7.1\lib\ant-launcher.jar;C:\Java\apache-ant-1.7.1\lib\ant-netrexx.jar;C:\Java\apache-ant-1.7.1\lib\ant-nodeps.jar;C:\Java\apache-ant-1.7.1\lib\ant-starteam.jar;C:\Java\apache-ant-1.7.1\lib\ant-stylebook.jar;C:\Java\apache-ant-1.7.1\lib\ant-swing.jar;C:\Java\apache-ant-1.7.1\lib\ant-testutil.jar;C:\Java\apache-ant-1.7.1\lib\ant-trax.jar;C:\Java\apache-ant-1.7.1\lib\ant-weblogic.jar;C:\Java\apache-ant-1.7.1\lib\ant.jar;C:\Java\apache-ant-1.7.1\lib\xercesImpl.jar;C:\Java\apache-ant-1.7.1\lib\xml-apis.jar;C:\Java\jdk1.6.0_02\lib\tools.jar;C:\Program Files\JetBrains\IntelliJ IDEA 6.0\lib\idea_rt.jar" com.intellij.rt.ant.execution.AntMain2 -logger com.intellij.rt.ant.execution.IdeaAntLogger2 -inputhandler com.intellij.rt.ant.execution.IdeaInputHandler -buildfile C:\Java\Projects\CcMailer\ccmailer.xml jar I suspect the inputhandler parameter has something to do with the problem, but if I run it myself the problem is not reproduced. Either way, I have only limited control over what IntelliJ does. My question is: how does IntelliJ even know the process is running? The Ant process is long gone. Is there a way to start a subprocess in a more sneaky way, so that IntelliJ won't even know there's anything to wait around for? Here's what I've tried so far: I tried using the start command, like this: <exec dir="." executable="cmd.exe" spawn="true"> <arg line="/c start cmd /c c:\Java\james-2.3.2\bin\debug.bat" /> </exec> I also tried using python, with code like this: import os.path import subprocess subprocess.Popen(["cmd.exe", "/c", "debug.bat"], stdin=open(os.path.devnull), stdout=open(os.path.devnull, "w"), stderr=subprocess.STDOUT) To no avail. The build window always stays up until I kill the server. Any ideas?

    Read the article

  • Migrating from CPython to Jython

    - by itsadok
    I'm considering moving my code (around 30K LOC) from CPython to Jython, so that I could have better integration with my java code. Is there a checklist or a guide I should look at, to help my with the migration? Does anyone have experience with doing something similar? From reading the Jython site, most of the problems seem too obscure to bother me. I did notice that: thread safety is an issue Unicode support seems to be quite different, which may be a problem for me mysqldb doesn't work and needs to be replaced with zxJDBC Anything else? Related question: What are some strategies to write python code that works in CPython, Jython and IronPython

    Read the article

  • Alternating table row colors in freemarker

    - by itsadok
    What's a good, simple way to have alternate row coloring with freemarker? Is this really the best way? <#assign row=0> <#list items as item> <#if (row % 2) == 0> <#assign bgcolor="green"> <#else> <#assign bgcolor="red"> </#if> <tr style='background-color: ${bgcolor}'><td>${item}</td></tr> <#assign row = row + 1> </#list> I tried doing this: <#assign row=0> <#list items as item> <tr style='background-color: ${(row % 2) == 0 ? "green" : "blue"}'><td>${item}</td></tr> <#assign row = row + 1> </#list> But apparently you can't user the ternary operator in there. Note: I guess I should have mentioned it earlier, but I can't use css classes or javascript, since this HTML is going into an email message.

    Read the article

  • Is there a good blogging platform to use as a framework?

    - by itsadok
    I'm writing a new product, and I've noticed that a lot of the features I want already exist in blogging platforms like wordpress. For example, comments and comment moderation, content editing, etc. Is there a good blogging system that is easy to use as a foundation for something else? Something with an API, extremely customizable, and hopefully something that works well with Java.

    Read the article

  • pubsubhubbub link with Project Rome

    - by itsadok
    I want to use Project Rome to create an RSS feed, using the code from the tutorial as base. I would like to add a pubsubhubbub discovery link, but there doesn't seem to be a general way to do so. I can use a Link object if I create an atom feed (which I don't want to limit myself to), or I can just add foreign markup, like this: // import org.jdom.Element Element element = new Element("link"); element.setAttribute("rel", "hub"); element.setAttribute("href", "https://myhub.example.com/endpoint"); feed.setForeignMarkup(Arrays.asList(element)); But it feels ugly. Is this really the best way to do this?

    Read the article

  • Wanted: a very simple java RegExp API

    - by itsadok
    I'm tired of writing Pattern p = Pattern.compile(... Matcher m = p.matcher(str); if (m.find()) { ... Over and over again in my code. I was going to write a helper class to make it neater, but I then I wondered: is there a library that tries to provide a simpler facade for Regular Expressions in Java? I'm thinking something in the style of commons-lang and Guava.

    Read the article

  • vlc python bindings - how to receive keyboard input?

    - by itsadok
    I'm trying to use VLC's python bindings to create my own little video player. The demo implementation is quite simple and nice, but it requires all the keyboard commands to be typed into the console from which the script was run. Is there any way I can handle keyboard input also when the video player itself has focus? Specifically, I care about controlling the video while in fullscreen mode. Perhaps there's a way to keep the keyboard focus in the console (or maybe another window) while showing the video? I'm using Windows XP, if that has any relevance.

    Read the article

  • SAXException: Unexpected end of file after null

    - by itsadok
    I'm getting the error in the title occasionally from a process the parses lots of XML files. The files themselves seem OK, and running the process again on the same files that generated the error works just fine. The exception occurs on a call to XMLReader.parse(InputStream is) Could this be a bug in the parser (I use piccolo)? Or is it something about how I open the file stream? No multithreading is involved. Piccolo seemed like a good idea at the time, but I don't really have a good excuse for using it. I will to try to switch to the default SAX parser and see if that helps. Update: It didn't help, and I found that Piccolo is considerably faster for some of the workloads, so I went back.

    Read the article

  • pubsub link with Project Rome

    - by itsadok
    I want to use Project Rome to create an RSS feed, using the code from the tutorial as base. I would like to add a pubsubhubbub discovery link, but there doesn't seem to be a general way to do so. I can use a Link object if I create an atom feed (which I don't want to limit myself to), or I can just add foreign markup, like this: // import org.jdom.Element Element element = new Element("link"); element.setAttribute("rel", "hub"); element.setAttribute("href", "https://myhub.example.com/endpoint"); feed.setForeignMarkup(Arrays.asList(element)); But it feels ugly. Is this really the best way to do this?

    Read the article

1