Search Results

Search found 6758 results on 271 pages for 'shell exec'.

Page 110/271 | < Previous Page | 106 107 108 109 110 111 112 113 114 115 116 117  | Next Page >

  • How do I use a datetime variable with createparameter in classic ASP?

    - by Frank Schmitt
    I'm having a heck of a time trying to create a parameterized query that binds a date variable into a stored procedure call: twoyearsago = dateadd("yyyy", -2, date()) DataConn.ConnectionString = myConnectionString DataConn.Open Set rs = Server.CreateObject("ADODB.Recordset") Set DataCmd = Server.CreateObject("ADODB.Command") DataCmd.ActiveConnection = DataConn DataCmd.CommandText = "exec myStoredProc ?, ?" DataCmd.Parameters.Append DataCmd.CreateParameter("@start", adDate, , 10, date()) DataCmd.Parameters.Append DataCmd.CreateParameter("@end", adDate, , 10, twoyearsago) rs.Open DataCmd The stored proc returns nothing (indicating the dates aren't making it through). If I hard code dates in the query, e.g.: DataCmd.CommandText = "exec myStoredProc '01/01/2008', '01/01/2010'" I get the results I would expect. Calling CStr on my dates (if that makes a difference) returns them in the above format.

    Read the article

  • Eclipse Code Templates with Cobol

    - by Bruno Brant
    People, My team is just beginning to learn how to use COBOL on Eclipse (as part of the Rational Developer for System Z package) and one of our most desired features are code templates or code snippets. What we'd like to have is a code completion based on snippets just like we have on Java. For example, when I type try and hit ctrl-space Eclipse shows me a list of completion options, where one of those is create a try/catch block. Well, in COBOL one could leverage this when creating, for example, embedded SQL blocks, like EXEC SQL SELECT field, field, field, FROM table WHERE field = value, field = value END-EXEC. However, for some reason, it seems that Eclipse treats COBOL a little differently (no wonder why) from other languages. As such, when looking for the code templates in the preferences menu for COBOL, its appearance is very different from the Java one. The question is: how does one uses Eclipse's code templates with COBOL?

    Read the article

  • Good book for a software developer doing part-time (Linux) system administration work

    - by Tony Meyer
    In many smaller organisations, developers often end up doing some system administration work (for obvious reasons). A lot of the time, they have great developer skills, but few system administration skills (perhaps all self-taught), and so have to learn as they go, which is fairly inefficient. Are there canonical (or simply great) books that would help in this situation? More advanced than just using a shell (presumably a developer can do that), but not aimed at someone that hopes to spend many years doing this work. Ideally, something fairly generic (although specific to a distribution would be OK), covering databases, networking, general maintenance, etc, not just one specific task. For the most part, I'm interested in shell-based work (i.e. no GUI installed), although if there's something outstanding I'm missing, please point it out. (As an analogy, replace "system administration" with C, and I'd want K&R, with C++ and I'd want Meyers' "Effective C++").

    Read the article

  • CYGWin and sshd. Accepts authentication, but won't connect

    - by timramich
    Everything I find relating to this is the "ssh-exchange-identification:" error. This doesn't happen for me. I get two lines: Connection to localhost closed by remote host. Connection to localhost closed. ssh -v localhost spits out: OpenSSH_5.8p1, OpenSSL 0.9.8r 8 Feb 2011 debug1: Reading configuration data /etc/ssh_config debug1: Connecting to localhost [::1] port 22. debug1: Connection established. debug1: identity file /home/tim/.ssh/id_rsa type -1 debug1: identity file /home/tim/.ssh/id_rsa-cert type -1 debug1: identity file /home/tim/.ssh/id_dsa type -1 debug1: identity file /home/tim/.ssh/id_dsa-cert type -1 debug1: identity file /home/tim/.ssh/id_ecdsa type -1 debug1: identity file /home/tim/.ssh/id_ecdsa-cert type -1 debug1: Remote protocol version 2.0, remote software version OpenSSH_5.8 debug1: match: OpenSSH_5.8 pat OpenSSH* debug1: Enabling compatibility mode for protocol 2.0 debug1: Local version string SSH-2.0-OpenSSH_5.8 debug1: SSH2_MSG_KEXINIT sent debug1: SSH2_MSG_KEXINIT received debug1: kex: server->client aes128-ctr hmac-md5 none debug1: kex: client->server aes128-ctr hmac-md5 none debug1: sending SSH2_MSG_KEX_ECDH_INIT debug1: expecting SSH2_MSG_KEX_ECDH_REPLY debug1: Server host key: ECDSA 64:e3:27:90:ef:48:93:21:38:ea:9b:0e:0b:07:b0:2a debug1: Host 'localhost' is known and matches the ECDSA host key. debug1: Found key in /home/tim/.ssh/known_hosts:1 debug1: ssh_ecdsa_verify: signature correct debug1: SSH2_MSG_NEWKEYS sent debug1: expecting SSH2_MSG_NEWKEYS debug1: SSH2_MSG_NEWKEYS received debug1: Roaming not allowed by server debug1: SSH2_MSG_SERVICE_REQUEST sent debug1: SSH2_MSG_SERVICE_ACCEPT received debug1: Authentications that can continue: publickey,password,keyboard-interactive debug1: Next authentication method: publickey debug1: Trying private key: /home/tim/.ssh/id_rsa debug1: Trying private key: /home/tim/.ssh/id_dsa debug1: Trying private key: /home/tim/.ssh/id_ecdsa debug1: Next authentication method: keyboard-interactive debug1: Authentications that can continue: publickey,password,keyboard-interactive debug1: Next authentication method: password tim@localhost's password: debug1: Authentication succeeded (password). Authenticated to localhost ([::1]:22). debug1: channel 0: new [client-session] debug1: Requesting [email protected] debug1: Entering interactive session. debug1: channel 0: free: client-session, nchannels 1 Connection to localhost closed by remote host. Connection to localhost closed. Transferred: sent 2008, received 1376 bytes, in 0.0 seconds Bytes per second: sent 64774.0, received 44387.0 debug1: Exit status -1 I'm really at wit's end here because I couldn't get Windows' remote shell to even work. I'm so sick of using VNC just to get to a shell. Plus Windows' shell sucks because there is nothing like screen. Thanks

    Read the article

  • Cannot create a row of size 8074 which is greater than the allowable maximum row size of 8060.

    - by Lieven Cardoen
    I have already asked a question about this, but the problems keeps on hitting me ;-) I have two tables that are identical. I want to add a xml column. In the first table this is no problem, but in the second table I get the sqlException (title). However, apart from the data in it, they are the same. So, can I get the sqlException because of data in the table? I have also tried to store the field off page with EXEC sp_tableoption 'dbo.PackageSessionNodesFinished', 'large value types out of row', 1 but without any succes. The same SqlException keeps coming. First table: PackageSessionNodes CREATE TABLE [dbo].[PackageSessionNodes]( [PackageSessionNodeId] [int] IDENTITY(1,1) NOT NULL, [PackageSessionId] [int] NOT NULL, [TreeNodeId] [int] NOT NULL, [Duration] [int] NULL, [Score] [float] NOT NULL, [ScoreMax] [float] NOT NULL, [Interactions] [xml] NOT NULL, [BrainTeaser] [bit] NULL, [DateCreated] [datetime] NULL, [CompletionStatus] [int] NOT NULL, [ReducedScore] [float] NOT NULL, [ReducedScoreMax] [float] NOT NULL, [ContentInteractions] [xml] NOT NULL, CONSTRAINT [PK_PackageSessionNodes] PRIMARY KEY CLUSTERED ( [PackageSessionNodeId] ASC )WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY] ) ON [PRIMARY] Second table: PackageSessionNodesFinished CREATE TABLE [dbo].[PackageSessionNodesFinished]( [PackageSessionNodeFinishedId] [int] IDENTITY(1,1) NOT NULL, [PackageSessionId] [int] NOT NULL, [TreeNodeId] [int] NOT NULL, [Duration] [int] NULL, [Score] [float] NOT NULL, [ScoreMax] [float] NOT NULL, [Interactions] [xml] NOT NULL, [BrainTeaser] [bit] NULL, [DateCreated] [datetime] NULL, [CompletionStatus] [int] NOT NULL, [ReducedScore] [float] NOT NULL, [ReducedScoreMax] [float] NOT NULL, [ContentInteractions] [xml] NULL, CONSTRAINT [PK_PackageSessionNodesFinished] PRIMARY KEY CLUSTERED ( [PackageSessionNodeFinishedId] ASC )WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY] ) ON [PRIMARY] First script I tried to run (First two ALTER TABLE work fine, the third crashes on SqlException) ALTER TABLE dbo.PackageSessionNodes ADD ContentInteractions xml NOT NULL CONSTRAINT DF_PackageSessionNodes_ContentInteractions DEFAULT (('<contentinteractions/>')); ALTER TABLE dbo.PackageSessionNodes DROP CONSTRAINT DF_PackageSessionNodes_ContentInteractions ALTER TABLE dbo.PackageSessionNodesFinished ADD ContentInteractions xml NOT NULL CONSTRAINT DF_PackageSessionNodesFinished_ContentInteractions DEFAULT (('<contentinteractions/>')); ALTER TABLE dbo.PackageSessionNodesFinished DROP CONSTRAINT DF_PackageSessionNodesFinished_ContentInteractions Second script I tried to run with the same result as previous script: EXEC sp_tableoption 'dbo.PackageSessionNodes', 'large value types out of row', 1 ALTER TABLE dbo.PackageSessionNodes ADD ContentInteractions xml NOT NULL CONSTRAINT DF_PackageSessionNodes_ContentInteractions DEFAULT (('<contentinteractions/>')); ALTER TABLE dbo.PackageSessionNodes DROP CONSTRAINT DF_PackageSessionNodes_ContentInteractions EXEC sp_tableoption 'dbo.PackageSessionNodesFinished', 'large value types out of row', 1 ALTER TABLE dbo.PackageSessionNodesFinished ADD ContentInteractions xml NOT NULL CONSTRAINT DF_PackageSessionNodesFinished_ContentInteractions DEFAULT (('<contentinteractions/>')); ALTER TABLE dbo.PackageSessionNodesFinished DROP CONSTRAINT DF_PackageSessionNodesFinished_ContentInteractions Now, In PackageSessionNodes there are 234 records, in PackageSessionNodesFinished there are 4256946 records. Really would appreciate some help here as I'm stuck.

    Read the article

  • which package i should choose, if i want to install virtualenv for python?

    - by hugemeow
    pip search just returns so many matches, i am confused about which package i should choose to install .. should i only install virtualenv? or i'd better also install virtualenv-commands and virtualenv-commands, etc, but i really don't know exactly what virtualenv-commands is ... mirror0@lab:~$ pip search virtualenv virtualenvwrapper - Enhancements to virtualenv virtualenv - Virtual Python Environment builder veh - virtualenv for hg pyutilib.virtualenv - PyUtilib utility for building custom virtualenv bootstrap scripts. envbuilder - A package for automatic generation of virtualenvs virtstrap-core - A bootstrapping mechanism for virtualenv+pip and shell scripts tox - virtualenv-based automation of test activities virtualenvwrapper-win - Port of Doug Hellmann's virtualenvwrapper to Windows batch scripts everyapp.bootstrap - Enhanced virtualenv bootstrap script creation. orb - pip/virtualenv shell script wrapper monupco-virtualenv-python - monupco.com registration agent for stand-alone Python virtualenv applications virtualenvwrapper-powershell - Enhancements to virtualenv (for Windows). A clone of Doug Hellmann's virtualenvwrapper RVirtualEnv - relocatable python virtual environment virtualenv-clone - script to clone virtualenvs. virtualenvcontext - switch virtualenvs with a python context manager lessrb - Wrapper for ruby less so that it's in a virtualenv. carton - make self-extracting virtualenvs virtualenv5 - Virtual Python 3 Environment builder clever-alexis - Clever redhead girl that builds and packs Python project with Virtualenv into rpm, deb, etc. kforgeinstall - Virtualenv bootstrap script for KForge pypyenv - Install PyPy in virtualenv virtualenv-distribute - Virtual Python Environment builder virtualenvwrapper.project - virtualenvwrapper plugin to manage a project work directory virtualenv-commands - Additional commands for virtualenv. rjm.recipe.venv - zc.buildout recipe to turn the entire buildout tree into a virtualenv virtualenvwrapper.bitbucket - virtualenvwrapper plugin to manage a project work directory based on a BitBucket repository tg_bootstrap - Bootstrap a TurboGears app in a VirtualEnv django-env - Automaticly manages virtualenv for django project virtual-node - Install node.js into your virtualenv django-environment - A plugin for virtualenvwrapper that makes setting up and creating new Django environments easier. vip - vip is a simple library that makes your python aware of existing virtualenv underneath. virtualenvwrapper.django - virtualenvwrapper plugin to create a Django project work directory terrarium - Package and ship relocatable python virtualenvs venv_dependencies - Easy to install any dependencies in a virtualenviroment(without making symlinks by hand and etc...) virtualenv-sh - Convenient shell interface to virtualenv virtualenvwrapper.github - Plugin for virtualenvwrapper to automatically create projects based on github repositories. virtualenvwrapper.configvar - Plugin for virtualenvwrapper to automatically export config vars found in your project level .env file. virtualenvwrapper-emacs-desktop - virtualenvwrapper plugin to control emacs desktop mode bootstrapper - Bootstrap Python projects with virtualenv and pip. virtualenv3 - Obsolete fork of virtualenv isotoma.depends.zope2_13_8 - Running zope in a virtualenv virtual-less - Install lessc into your virtualenv virtualenvwrapper.tmpenv - Temporary virtualenvs are automatically deleted when deactivated isotoma.plone.heroku - Tooling for running Plone on heroku in a virtualenv gae-virtualenv - Using virtualenv with zipimport on Google App Engine pinvenv - VirtualEnv plugins for pin isotoma.depends.plone4_1 - Running plone in a virtualenv virtualenv-tools - A set of tools for virtualenv virtualenvwrapper.npm - Plugin for virtualenvwrapper to automatically encapsulate inside the virtual environment any npm installed globaly when the venv is activated d51.django.virtualenv.test_runner - Simple package for running isolated Django tests from within virtualenv difio-virtualenv-python - Difio registration agent for stand-alone Python virtualenv applications VirtualEnvManager - A package to manage various virtual environments. virtualenvwrapper.gem - Plugin for virtualenvwrapper to automatically encapsulate inside the virtual environment any gems installed when the venv is activated

    Read the article

  • I have a error building a .vdproj on msbuild with nant

    - by Luís Custódio
    I'm getting used to using nant for build releases. But I have started to use asp.net MVC, and i choice make the setup for installation with a .vdproj . But, when I call the: < exec program="${dotnet.dir}/msbuild.exe" commandline='"./Wum.sln" /v:q /nologo /p:Configuration=Release' / in nant, my result is: [exec] D:\My Documents\Visual Studio 2008\Projects\Wum\Wum.sln : warning MS B4078: The project file "Wum.Setup\Wum.Setup.vdproj" is not supported by MSBuild and cannot be built. Someone have some clue, or a solution? If I use the devenv, I'll have a problem? Thanks in advance.

    Read the article

  • MSSQL2008: DTC Transaction - Internal abort

    - by Teutales
    Hi all, I write a small own replication - a trigger which fires an DTC INSERT to another server (one reason for my own "replication": while trigger is running it calculates some data, another: it works from an express version to an express version). When I do the initial insert from the same Host with the windows authentification it works fine. But there is a webserver on another host, which uses the sqlserver login (for testing sa). When this Host do the initial insert I get a Internal abort after the entlisting and creating phase in the DTCTransaction EventClass (Profiler). The magic is: When I first fire it from the same Host with the windows authentification, I can fire it from the webserver and it works fine. But I just have to wait some minutes and it won't work. Where is my error in reasoning... Thanks! Greetz Teutales Here is my initial server script: EXEC master.dbo.sp_addlinkedserver @server = @Servername, @srvproduct=N'SQL Server' EXEC master.dbo.sp_addlinkedsrvlogin @rmtsrvname = @Servername, @locallogin = NULL , @useself = N'False', @rmtuser = @Serverlogin, @rmtpassword = @Serverpwd

    Read the article

  • DataTable identity column not set after DataAdapter.Update/Refresh on table with "instead of"-trigge

    - by Arno
    Within our unit tests we use plain ADO.NET (DataTable, DataAdapter) for preparing the database resp. checking the results, while the tested components themselves run under NHibernate 2.1. .NET version is 3.5, SqlServer version is 2005. The database tables have identity columns as primary keys. Some tables apply instead-of-insert/update triggers (this is due to backward compatibility, nothing I can change). The triggers generally work like this: create trigger dbo.emp_insert on dbo.emp instead of insert as begin set nocount on insert into emp ... select @@identity end The insert statement issued by the ADO.NET DataAdapter (generated on-the-fly by a thin ADO.NET wrapper) tries to retrieve the identity value back into the DataRow: exec sp_executesql N' insert into emp (...) values (...); select id, ... from emp where id = @@identity ' But the DataRow's id-Column is still 0. When I remove the trigger temporarily, it works fine - the id-Column then holds the identity value set by the database. NHibernate on the other hand uses this kind of insert statement: exec sp_executesql N' insert into emp (...) values (...); select scope_identity() ' This works, the NHibernate POCO has its id property correctly set right after flushing. Which seems a little bit counter-intuitive to me, as I expected the trigger to run in a different scope, hence @@identity should be a better fit than scope_identity(). So I thought no problem, I will apply scope_identity() instead of @@identity under ADO.NET as well. But this has no effect, the DataRow value is still not updated accordingly. And now for the best part: When I copy and paste those two statements from SqlServer profiler into a Management Studio query (that is including "exec sp_executesql"), and run them there, the results seem to be inverse! There the ADO.NET version works, and the NHibernate version doesn't (select scope_identity() returns null). I tried several times to verify, but to no avail. Of course this just shows the resultset coming from the database, whatever happens inside NHibernate and ADO.NET is another topic. Also, several session properties defined by T-SQL SET are different in the two scenarios (Management Studio query vs. application at runtime) This is a real puzzle to me. I would be happy about any insights on that. Thank you!

    Read the article

  • Using Python on Mac

    - by choise
    hi, i want to learn python using my mac. now i want to setup a python version = 3.1.3, because my materials for learning are using this version. typing python into terminal results version 2.6.1, using the dmg installer on python.org (http://docs.python.org/ftp/python/3.1.3/) doesn't have an effect on the python version in terminal, but it's bundled with an own shell under Applications/Python 3.1/Idle.app my question now is, should i use this shell for learing or is there a better way, updating the python version bundled with snow leopard? i already tried defaults write com.apple.versioner.python Version 3.1.3 or defaults write com.apple.versioner.python Version 3.0 without any result. thanks!

    Read the article

  • "Breadcrumbs" for series of hostnames?

    - by Hamy
    Does anyone know of a shell that would show a series of breadcrumbs as I navigate into/out of various servers, like this: Home > Build Machine > Vagrant > Docker-base Hopefully it could auto-detect logging in and out of various boxes and display the hostnames. Perhaps with a simple "no circular links", one could just try and monitor the hostname, but I don't know if there is a shell that can easily act as a 'parent' to the other shells on these various systems so that it can query hostname and/or other item. Any thoughts?

    Read the article

  • How does one get Vista to display .MOV thumbnails as a frame from the movie?

    - by Paul Hollingsworth
    I've discovered that Windows Vista explorer shell does not display proper "thumbnail"s for .MOV files. e.g. For .JPG files, the explorer shell, when in Thumbnail mode, displays a scaled down version of the image. But for .MOV files, it displays the same icon as in the non-thumbnail view, which is just some generic thing that shows you it's going to be played with Quicktime or whatever. What XP used to do was show you a frame from the actual movie as the thumbnail. I've looked on internet and found various proposed solutions, but none which actually work. Is there a simple step-by-step process for getting Vista to properly display thumbnails for .MOV files?

    Read the article

  • Different color prompts for different machines when using terminal/ssh?

    - by bcrawl
    I have 5 machines I constantly ssh into to do work. Its getting increasingly frustrating when I am issuing wrong commands on wrong boxes. Luckily I havent done anything bad yet. I wanted to know if there is any hack which I can hardcode which will display my prompt in different colors based on the machine I am ssh into? Such as blue for desktop1, purple for laptop, red for server etc? Is this possible? Currently I am using this command export PS1="\e[0;31m[\u@\h \W]\$ \e[m " taken from here http://www.cyberciti.biz/faq/bash-shell-change-the-color-of-my-shell-prompt-under-linux-or-unix/ but it obviously doesnt work across ssh. Also, if you have any other cool bash tips for helping me ease my sight will be wonderful. I got this tip which colors the man pages. http://linuxtidbits.wordpress.com/2009/03/23/less-colors-for-man-pages/

    Read the article

  • Ant build.xml requires user input, but Eclipse has no tty

    - by carneades
    I'm trying to better integrate Eclipse with my build.xml. My build file calls GNU Make for the native portion of the program, and the Makefile uses sudo to movethe compiled libs into system path. Unfortunately that requires entering a password, and Eclipse's terminal doesn't accept user input. So the result from running the build in eclipse is: [exec] sudo: no tty present and no askpass program specified [exec] make: *** [install] Error 1 Any way around this problem? Can the ant build be elevated to root some other way?

    Read the article

  • vbscript calling svnadmin dump

    - by Dexton
    Hi, Running the following vbscript to call svnadmin dump fails (i.e. no dump is being created) Set objShell = CreateObject("WScript.Shell") Set objShellExec = objShell.Exec("svnadmin dump C:\svn_repos > C:\fullbackup") I discovered from another post, http://stackoverflow.com/questions/445121/svn-dump-fails-with-wscript-shell/2400011#2400011 that i had to create a new command interpreter using cmd as follows: Set objShellExec = objShell.Exec("%comspec% /c" & "svnadmin dump C:\svn_repos > C:\fullbackup") This successfully created the dump but I could never read the output information (i.e. * Dumped revision 100. * Dumped revision 101. etc). I tried Do While objWshScriptExec.Status = 0 Wscript.Echo objShellExec.StdOut.Readline Wscript.Echo objShellExec.StdErr.Readline WScript.Sleep 100 Loop but nothing ever gets displayed. May I know how i can read the output information and also why I needed to create a new command interpreter using "%comspec% /c" before the svnadmin dump command would execute correctly? Thanks. Regards, Dexton

    Read the article

  • qemu command not running directly

    - by Dr. Death
    Can I use "qemu://localhost/system " command directly inplace of "virsh -c qemu://localhost/system " command if my both machines are physically connected in a network as virsh will simply creating the virtual shell between two systems? can I use ssh in place of virtual shell here? I tried this but system gives no directory or file name for qemu even when i had qemu installed properly in my system. but when i use virsh i did not get such errors. Do i need to open any unix socket for doing this?

    Read the article

  • Configuring TMUX's status bar

    - by wdkrnls
    I want my tmux session to show my current ip address in the right hand side of the status bar but I am having the hardest time figuring up the right syntax. The command works perfectly in the shell, but tmux won't parse it. set -g status-right '#[fg=white]#(host (hostname))' [Note: I am using the fish shell] I really want it to be: set -g status-right '#[fg=white]#(hostname)@#(host (hostname) | cut -d " " -f 4)' But since I can't get the former status bar to work, this is a lost cause. The weird thing is I got the first one to work once, but then I added the cut.

    Read the article

  • Running lame from php

    - by gok
    I am trying to run lame from a php script. I have tried these, but no luck, I don't get anything returned! Any ideas? system('lame', $returnarr); system('lame --help', $returnarr); exec('lame', $returnarr); passthru('lame', $returnarr); even this one returns nothing: exec('which lame', $returnarr); I am on OSX and final deployment will be on Linux. Do you have better suggestions for an automated wav-mp3 conversion? From php, should I execute a bash script that executes Lame?

    Read the article

  • adding mongo to path

    - by Mike
    Bit of a noob question. I have downloaded MongoDb and installed it here /Users/mike/downloads/mongodb In order to start it, I then have to 'cd' into the 'bin' /Users/mike/downloads/mongodb/bin and run ./mongod (to start the database) and ./mongo (to start the mongo shell) The problem is that I can only work with python and ruby scripts using the mongo shell if I have those scripts stored in the same bin directory, and I don't think that's the ideal set up. Will exporting the path allow me to access mongo from outside the bin? For example, I would prefer to have my ruby scripts in /sites/ruby and be able to access mongo by starting ruby in /sites/ruby. If exporting to path is the solution, how do I do that. I'm using a mac

    Read the article

  • Debugging in Maven?

    - by aduric
    Is it possible to launch a debugger such as jdb from maven? I have a pom.xml file that compiles the project successfully. However, the program hangs somewhere and I would really like to launch jdb or an equivalent debugger to see what's happening. I compile using mvn compile and launch using: mvn exec:java -Dexec.mainClass="com.mycompany.app.App" I was expecting something like: mvn exec:jdb -Dexec.mainClass="com.mycompany.app.App" to launch the debugger but, as usual, my expectations are incongruent with maven's philosophy. Also, I couldn't find any documentation (on Maven's website or google) to describe how debugging works. I suspect that I have to use some plugin.

    Read the article

  • Accessing Python module fails although its package is imported

    - by codethief
    Hey Stackers! :) My Django project's directory hierarchy looks like this: + pybsd |---+ devices |---+ templates |---+ views |---+ interaction |---- __init__.py |---- geraete.py |---- geraetemodelle.py |---- geraetegruppen.py |---- __init__.py |---- ajax.py |---- html.py |---- misc.py |---- __init__.py |---- urls.py |---- __init__.py |---- urls.py (Please excuse the German names. I preferred not to replace them here since it would add yet another possible error source when trying out the solutions you'll hopefully suggest and answering your questions.) Every request to http://URL/devices/.* is dispatched to the urls.py file living in /devices: # ... from views import html, ajax, misc, interaction urlpatterns = patterns('', # ... (r'^ajax/update/(?P<table>[a-z_]+)$', ajax.update), (r'^ajax/delete/(?P<table>[a-z_]+)$', ajax.delete), (r'^ajax/select_options/(?P<table>[a-z_]+)$', ajax.select_options), (r'^interaction/geraete/info/(?P<geraet>\d+)$', interaction.geraete.info), (r'^interaction/geraete/delete/(?P<geraet>\d+)?$', interaction.geraete.delete), (r'^interaction/geraetemodelle/delete/(?P<geraetemodell>\d+)?$', interaction.geraetemodelle.delete), (r'^interaction/geraetegruppen/delete/(?P<geraetegruppe>\d+)?$', interaction.geraetegruppen.delete), # ... ) All URL definitions work except for those referencing the interaction package. I'm constantly getting the following error: File "/home/simon/projekte/pybsd/../pybsd/devices/urls.py", line 33, in `<module>` (r'^interaction/geraete/info/(?P<geraet>\d+)$', interaction.geraete.info), AttributeError: 'module' object has no attribute 'geraete' I double-checked that the __init__.py files don't contain anything. Maybe you've already found the (Python- or Django-related?) mistake I made and am apparently unable to see. If not, read on. In any case, thanks for reading this long post! Isolating the problem 1st test It works if I provide the view functions as strings: (r'^interaction/geraete/info/(?P<geraet>\d+)$', 'devices.views.interaction.geraete.info'), (r'^interaction/geraete/delete/(?P<geraet>\d+)?$', 'devices.views.interaction.geraete.delete'), (r'^interaction/geraetemodelle/delete/(?P<geraetemodell>\d+)?$', 'devices.views.interaction.geraetemodelle.delete'), (r'^interaction/geraetegruppen/delete/(?P<geraetegruppe>\d+)?$', 'devices.views.interaction.geraetegruppen.delete'), ... or add yet another line to the imports: from views.interaction import geraete, geraetemodelle, geraetegruppen Using from views.interaction import *, however, doesn't work either and results in the same error message. 2nd test I created a file test.py in /devices: from views import interaction print dir(interaction) Output: simon@bsd-simon:~/projekte/pybsd/devices$ python test.py ['__builtins__', '__doc__', '__file__', '__name__', '__package__', '__path__'] Again, no sign of the modules I created in the interaction package (geraete.py, geraetemodelle.py, geraetegruppen.py). Unlike in urls.py, trying from view.interaction import geraete, geraetegruppen, geraetemodelle in test.py results in ImportError: No module named view.interaction this time. 3rd test I started the Django shell: $ python manage.py shell >>> import devices.views.interaction.geraete >>> dir(devices.views.interaction.geraete) ['Abteilung', 'Auftrag', 'Auftragsvorlage', 'Geraet', 'Geraetegruppe', 'Geraetemodell', 'HttpResponse', 'HttpResponseBadRequest', 'HttpResponseRedirect', 'Raum', 'Standort', '__builtins__', '__doc__', '__file__', '__name__', '__package__', 'delete', 'info', 'models', 'move', 'render_to_response'] >>> $ python manage.py shell >>> from devices.views.interaction import geraete >>> dir(geraete) ['Abteilung', 'Auftrag', 'Auftragsvorlage', 'Geraet', 'Geraetegruppe', 'Geraetemodell', 'HttpResponse', 'HttpResponseBadRequest', 'HttpResponseRedirect', 'Raum', 'Standort', '__builtins__', '__doc__', '__file__', '__name__', '__package__', 'delete', 'info', 'models', 'move', 'render_to_response'] >>> $ python manage.py shell >>> import devices.views.interaction >>> devices.views.interaction.geraete Traceback (most recent call last): File "<console>", line 1, in <module> AttributeError: 'module' object has no attribute 'geraete' >>> dir(devices.views.interaction) ['__builtins__', '__doc__', '__file__', '__name__', '__package__', '__path__']

    Read the article

  • alternatives to SGE

    - by bmargulies
    Once upon at time there was the free SGE from Sun. tricky to install and configure, but functional and free. Now we've got: open source packages on Ubuntu that don't quite work out of the box (details on request). the actual source behind them, with a build process that depends on the c-shell and other obsolescences, available from two competing locations. a commercial packaging from Oracle a commercial package from Univa What I am really wishing for is something with the basic capabilities of this that is simple to install and maintain. Heck, I'd take a front-end to hadoop that just queues and distributes simple shell-script-defined jobs.

    Read the article

  • Qtestlib: QNetworkRequest not executed

    - by dzen
    I would like to test an asynchronous request to a webserver. For that purpose I'm creating a simple unittest to quickly try a few lines of code: void AsynchronousCall::testGet() { QNetworkAccessManager *nam = new QNetworkAccessManager(this); QUrl url("http://myownhttpserver.org"); QNetworkRequest req(url); this->connect(nam, SIGNAL(finished(QNetworkReply*)), this, SLOT(reqFinished(QNetworkReply *))); QNetworkReply *rep = nam->get(req); } void AsynchronousCall::reqFinished(QNetworkReply *rep) { qDebug() << rep->readAll(); qDebug() << "finshed"; } The problem is that reqFinished() is never reached. If I had a simple QEventLoop and and a loop.exec() just after the nam-get(req); the request is executed. Any hint ? Do I have to use a loop.exec() in my every unittests ?

    Read the article

  • Msys cd .. command takes me to home directory instead of parent

    - by Adrian
    I'm using Msys on Windows 7 with what I believe to be a Bash shell. I want to navigate the following directory structure: Drive (M:) +--- Coding +--- CPP +--- projects +--- other_folder_1 +--- other_folder_2 My fstab file contains the following line: M:/Coding/CPP/projects/ /home/Adrian/ ... which makes the projects folder my starting directory when opening the shell. Unfortunately when I try to cd .. out of projects, I end up in /home instead of CPP. I imagine this might be related to what I did in the fstab file. Is there any way for me to retain the projects folder as my starting directory while being able to cd into its parent directories?

    Read the article

< Previous Page | 106 107 108 109 110 111 112 113 114 115 116 117  | Next Page >