Is there a clean way to have your fabfile take command line arguments? I'm writing an installation script for a tool that I want to be able to specify an optional target directory via the command line.
I wrote some code to test what would happen if I passed in some command line arguments:
# fabfile.py
import sys
def install():
…
My graphics card is a nVidia GeForce GTX 660 2GB.
When I plug HDMI into mobo it works fine. When I plug it into the graphics card (with 2nd monitor too) it shows a purple vertical line on the left side. It adds 2 pixels to the width and I can't adjust it with my monitor. It doesn't come up when I print screen.
I tried changing the…
I try to make Fabric func, which checks if Apache installed:
from fabric.api import *
def check_apache():
try:
result = local('httpd -v', capture=True)
except:
print "check_apache exception"
But if httpd not installed I get:
[root@server-local ~]$ fab check_apache
Fatal error: local() encountered an…
To check HTTP response header for a set of urls I send with curl the following request headers
foreach ( $urls as $url )
{
// Setup headers - I used the same headers from Firefox version 2.0.0.6
$header[ ] = "Accept: text/xml,application/xml,application/xhtml+xml,";
$header[ ] =…
Hi,
I'm trying to deploy a django app with fabric and get the following
error:
Alexs-MacBook:fabric alex$ fab config:instance=peergw deploy -H <ip> -
u <username> -p <password>
[192.168.2.93] run: cat /etc/issue
Traceback (most recent call last):
File…
Is there a simple solution to do the equivalent of Java's comments:
<%-- this is a comment inside a template, it does not appear in the output HTML --%>
Even if you use short php tags, you still have to wrap the comments with comment syntax, on top of the php tags:
<?…
I want to use AIR to create an OFFLINE version of a "webapp" kind of website (lots of ajax, front end code).
Haven't been much further than the HelloWorld example, I keep wondering: how do you design your code, to maximize code reuse between the website (say in php or Java or…
How do you encode a javascript object/hash (pairs of properties and values) into a URL-encoded query string with YUI (2.7.0 or 3.0.0 Beta) ?
I want to do the equivalent of Object.toQueryString() from Prototype:
I need this to encode parameters for GET and POST requests with…
I'm pretty sure I saw somewhere in a popular Git project the branches had a pattern like "feature/xyz".
However when I try to create a branch with the slash character, I get an error:
$ git branch foo/bar
error: unable to resolve reference refs/heads/labs/feature: Not a…
I'm trying to find a way to use a command line nodejs application that I created on a computer without node.js installed. In other words how to package my application with node.js inside, in order to avoid the users to have node.js already installed.
The tipical use case…
I'm trying to use the Fabric 0.1.1 deploy tool (http://docs.fabfile.org/) on Windows and we're running into an issue with the readline module. I've been through various threads but can't seem to solve the issue. It's important because we can't deploy applications from…
I’ve been struggling trying to create the icons that are used for different tabs on an iPhone app. The difficulty is, is that each image is a PNG, but alpha channels are used to represent their selected state. I’ve just come across this fab tool, that takes…
I have problem with installation Ganeti Web Manager on Debian 6.0.6
fab prod deploy
Traceback (most recent call last):
File "/usr/lib/pymodules/python2.6/fabric/main.py", line 378, in main
docstring, callables = load_fabfile(fabfile)
File…
I am using the google dns servers most of the time, but for one particular wifi connection it blocks that ip so I have to revert back to automatically choosing DNS...
The problem now is everytime I connect to this network, I have to change it…
Working for a Microsoft partner I was very fortunate enough to be given clearance to order a Microsoft Surface RT tablet.
Justification, show new device to a customer event this Thursday.
All good, time to develop an App. Surface…
What is the best way to implement a decision tree in SharePoint? Is there a web part available? Does any of Sharepoint's Fab 40 templates contain a decision tree web part? i have searched but i couldnt find a useful answer anywhere.…
I use django, and have a lengthy models.py file.
class Foo(models.Model):
name = models.CharField()
class Bar(models.Model):
name = models.CharField()
class Fab(models.Model):
name = models.CharField()
Is there a…
I'd like to apply similar styling to elements like textboxs, checkboxes, etc. that my pref-fab jQuery UI theme applies to the jQuery UI widgets. Is there a solid way to do this, or is it a mix and match process manually choosing…
i want to untar file from source to destination
with below statement
`def untar(source,destination):
run("tar -xf {0} {1}".format(source,destination))
`
i am getting Error
C:\Users\test\Desktop\fabric>fab -H user@host-p…
Bugged by the irritating "Path is too long after being fully qualified" error while running in the Development Fabric? The solution is pretty funny and not so obvious unfortunately. The culprit here is not your app, but the…
Not the next installment quite yet, just an update from what I knew yesterday. Right after I posted the Real Excel Templates I. Mike from the PM team got in touch to say he and Shirley had just had a meeting with a customer…
I'm currently undertaking a personal project at home that I need to turn around inside the next few months (which working full time and still learning programming makes it a tad difficult). I'm looking for suggestions on…
Yes, I know, the best way to make an indie game is to learn to code. I've got some scripting experience, but I want to do worldbuilding with already-existing tools (and communities surrounding those tools), and I've been…