Hi. how can I clear the .viminfo file.
I want to clear the Command Line History,File marks, Jumplist etc.,
other then Search String History
Is there any way to do this.
I have a custom Tab Control that I have created, but I am having an issue. I have an Editable TextBox as part of the custom TabControl View.
<Controls:EditableTextControl x:Name="PageTypeName"
Style="{StaticResource ResourceKey={x:Type Controls:EditableTextControl}}" Grid.Row="0" TabIndex="0"
Uid="0"
AutomationProperties.AutomationId="PageTypeNameTextBox"
AutomationProperties.Name="PageTypeName"
Visibility="{Binding ElementName=PageTabControl,Path=ShowPageType}">
<Controls:EditableTextControl.ContextMenu>
<ContextMenu x:Name="TabContextMenu">
<MenuItem Header="Rename Page Type" Command="{Binding Path=PlacementTarget.EnterEditMode, RelativeSource={RelativeSource AncestorType=ContextMenu}}"
AutomationProperties.AutomationId="RenamePageTypeMenuItem"
AutomationProperties.Name="RenamePageType"/>
<MenuItem Header="Delete Page Type" Command="{Binding Path=PageTypeDeletedCommand}"
AutomationProperties.AutomationId="DeletePageTypeMenuItem"
AutomationProperties.Name="DeletePageType"/>
</ContextMenu>
</Controls:EditableTextControl.ContextMenu>
<Controls:EditableTextControl.Content>
<!--<Binding Path="CurrentPageTypeViewModel.Name" Mode="TwoWay"/>-->
<Binding ElementName="PageTabControl" Path="CurrentPageTypeName" Mode ="TwoWay"/>
</Controls:EditableTextControl.Content>
</Controls:EditableTextControl>
In the Content section I am binding to a Dependency Prop called CurrentPageTypeName. This Depedency prop is part of this custom Tab Control.
public static DependencyProperty CurrentPageTypeNameProperty = DependencyProperty.Register("CurrentPageTypeName", typeof(object), typeof(TabControlView));
public object CurrentPageTypeName
{
get { return GetValue(CurrentPageTypeNameProperty) as object; }
set { SetValue(CurrentPageTypeNameProperty, value); }
}
In another view, where I am using the custom TabControl I then bind my property, with the actual name value, to CurrentPageTypeName property as seen below:
<Views:TabControlView Grid.Row="0" Name="RunPageTabControl"
TabItemsSource="{Binding RunPageTypeViewModels}"
SelectedTab="{Binding Converter={StaticResource debugConverter}}"
CurrentPageTypeName="{Binding Path=RunPageName, Mode=TwoWay}"
TabContentTemplateSelector="{StaticResource tabItemTemplateSelector}"
SelectedIndex="{Binding RelativeSource={RelativeSource FindAncestor, AncestorType={x:Type UserControl}}, Path=DataContext.SelectedTabIndex}"
ShowPageType="Hidden" >
<!--<Views:TabControlView.TabContentTemplate>
<DataTemplate DataType="{x:Type ViewModels:RunPageTypeViewModel}">
<RunViews:RunPageTypeView/>
</DataTemplate>
</Views:TabControlView.TabContentTemplate>-->
</Views:TabControlView>
My problem is that nothing seems to be happening. It is grabbing its Content from the Itemsource, and not from my chained Dependency props. Is what I am trying even possible? If so, what have I done wrong.
Thanks for looking.
If i have a # {} , like #{results}, in the snippet below:
results = Array.new
f = open("/Users/kahmed/messages", "r")
f.each_line do |line|
results << "#{$.} #{line}" if line =~ /NFE/
put #{results}
end
How can i use it in the following ssh.exec command
Net::SSH.start( HOST, USER, :password = PASS ) do|ssh|
ssh.exec(#{results})
I am trying to install balder - the carrier wave tree
i am getting some errors including:
not seeing the form elements for adding photos.
getting an error message "command exiftool not found"
I think I've installed all the gems and software already.
Anyone here good with troubleshooting code? also - i've got some screenshots handy if you need them. stackoverflow wont let me post images yet :/
also, are there any other alternative photo galleries written for ROR?
Is there a command in mercurial that will list all files currently under source control?
I can do a dir /s to list all files in my folder and subfolders, but I have no idea which have been added to my repository. I have a variety of excluded file types and folders and I want verify that none of them were added before I set them up in my .hgignore file.
I am using Maven 2.0.9 to build a multi module project. I have defined the assembly plugin in my parent pom. I can get my assemblies built using
mvn install assembly:assembly
This command runs the tests twice, once during install phase and another during assembly. I tried assembly:single but it throws an error. Any help to get my assemblies built without running the tests twice is much appreciated.
Hi,
anyone has tried to create a symfony form filter from a class which has a field of type "date" ?
When i do it, i get this error:
500 | Internal Server Error |
Doctrine_Connection_Mysql_Exception
SQLSTATE[HY093]: Invalid parameter
number: number of bound variables does
not match number of tokens stack trace
I think the error dependens on this command:
'SELECT b.id AS b_id, b.day AS b_day FROM birthday b WHERE b.day = ? AND
b.day <= ?', array('month' = '1','day' = '2', 'year' = '2014')
but i dont know how can i solve it..
Any idea?
Javi
I know it's a basic question but I've tried every combination of propedit propset, etc.
In an existing project, there's a file (let's call it 'error.log) I want to ignore for all future commits. What's the command-line syntax to do so?
I was wondering how such performance can be achieved on windows as I noticed snowberd is even faster than DOS "dir" command, even in mapped network drives...?
Any idea what algo/technology are used to get such fast directory browsing...?
I've got thousands of urls from many hosts I need to screenshot.
I can use the lib fine from the command line, but how can I integrate it into my code so I can take multiple screenshots simultaneously?
I think it's something to do with xvfb as with the answer to this question: http://stackoverflow.com/questions/1747022/how-to-kill-headless-x-server-started-via-python but I'm not sure what exactly.
I'm using launching firefox from the command line in a script to get snapshots of pages. These pages have basic http authentication. When using:
firefox http://user:[email protected]
Either a dialog appears, or authentication doesn't work at all.
Is there any option to make firefox open the page without showing the dialog?
I have an app on heroku which is being used by few users. However, I notice there are some data issues which i'd like to fix and stop the app in the mean time so users don't enter anything new.
Is there a way to stop the app on heroku rather than destroying it? I see that restart server command is there ...though I don't see anything like 'stop'
I've got some code that looks like the following. First, there's a simple Parser class for parsing command-line arguments with options.
class Parser
def initialize(&b); ...; end # Create new parser.
def parse(args = ARGV); ...; end # Consume command-line args.
def opt(...); ...; end # Declare supported option.
def die(...); ...; end # Validation handler.
end
Then I have my own Parsers module which holds some metadata about parsers that I want to track.
module Parsers
ParserMap = {}
def self.make_parser(kind, desc, &b)
b ||= lambda {}
module_eval {
ParserMap[kind] = {:desc => "", :validation => lambda {} }
ParserMap[kind][:desc] = desc
# Create new parser identified by `<Kind>Parser`. Making a Parser is very
# expensive, so we defer its creation until it's actually needed later
# by wrapping it in a lambda and calling it when we actually need it.
const_set(name_for_parser(kind), lambda { Parser.new(&b) })
}
end
# ...
end
Now when you want to add a new parser, you can call make_parser like so:
make_parser :db, "login to database" do
# Options that this parser knows how to parse.
opt :verbose, "be verbose with output messages"
opt :uid, "user id"
opt :pwd, "password"
end
Cool. But there's a problem. We want to optionally associate validation with each parser, so that we can write something like:
validation = lambda { |parser, opts|
parser.die unless opts[:uid] && opts[:pwd] # Must provide login.
}
The interface contract with Parser says that we can't do any validation until after Parser#parse has been called. So, we want to do the following:
Associate an optional block with every Parser we make with make_parser.
We also want to be able to run this block, ideally as a new method called Parser#validate. But any on-demand method is equally suitable.
How do we do that?
I need to be able to raise different types of audio notifications to the user. I need an "ok" and an "error" type sounds, I was hoping to be able to raise a simple beep and a critical stop type sound but I can only find the Beep() command which doesn't allow for differing sounds. Is there a library that does what I need or will I need to roll my own using the system wavs.
I'm trying to run down when a particular bug was created, but wading through the history is pretty time consuming. Is anyone familiar with a command line method to get a list of revisions where a line or range of lines changed?
svn and vault evangelists: I know, right....but you can't always pick the environment....
Following command converts date formated as MM/DD/YYYY to seconds.
date -d "01/21/2014" +%s
How can I convert DD/MM/YYYY formated date to seconds?
Thanks
I have a php script that has the following requirement command: require_once 'HTTP/OAuth.php'; the file HTTP/OAuth.php is in php's include_path that is .:/usr/lib/php.
Nevertheless in Eclipse the require_once line is marked with the following warning: Include filename: 'HTTP/OAuth.php' doesn't exist in project:
How can I make my project see the include_path so it can find the require_once file?
Thanks
ldj
Given a PDF, how can one get the layout mode of a PDF (or relative width/height) using a PHP lib or linux command line tool?
Using http://www.tecnick.com/public/code/cp%5Fdpage.php?aiocp%5Fdp=tcpdf which can set this variable on new PDFs, but for existing pdfs from adobe.
Thought of converting pdfs to ps, or using gs in some other way - like converting it to an image first, and getting the width and height of that. Is this the best way?
I cant seem to send an email using PHP's mail(). I have also tried PHPMailer and Swiftmail with no success. However, the following command on the server delivers mail successfully.
cat test.txt | mail -s "test mail" [email protected]
Is there a way to trace where the problem is coming from? mail() just seems to return true or false.
how do i convert ctrl+z to a string?
i am sending this as an AT COMMAND to an attached device to this computer
basically i just to put some chars in a string and ctrl+z in that string as well
Is there a way to delete unused indexes in Google App Engine Java application?
The only one way I was able to find is to create an empty Python GAE application and run the following command:
appcfg.py vacuum_indexes /path/to/myapp/
Is there a more intelligent way?
I can open a shell by using the :shell command in Vim, however I can't edit a file and at the same time use the shell.
Is there any way to split Vim in many Windows (or tabs), and have a shell opened in one of them?
Hi there,
recently I started using Emacs as a Python IDE, and it not quite intuitive... The problem I am struggling with right now is how to pass command line arguments to the inferior python shell when the buffer is evaluated with C-c C-c. Thanks for help.
Is there a library that can be used for implementing undo/redo functionality for DOM element manipulations in JavaScript?
I'm writing an app that moves around DOM elements, enables editing and deletion of those elements. There are event-handlers and other objects associated with each element operated upon.
Not sure whether I need to roll my own implementation of the Command pattern for this. Surely, there must be something available? If not, suggestions and pointers would be a great help.