FAQ Database Discussion Community


ffmpeg convert any file to any file

linux,ffmpeg,centos,command
I Want simple command to convert any supported file to any file with little possible video compression. for example avi to mp4 mp4 to 3gp . .etc.. I tried below code ffmpeg -i infile.flv outfile.3gp It works for some but for some other like flv to 3gp conversion it throws...

Diference between pkt_duration and pkt_duration_time in ffprobe

ffmpeg,command,ffprobe
When I execute next ffprobe command in an HLS stream with parameter to show frames in specific stream video in flat format and grep with 'pkt' pattern, it returns this info: $ ffprobe -i http://xxxxxxxxxxxxxxxx/PCMDY_SUB.m3u8 -show_frames -select_streams v:0 -print_format flat | grep pkt ... frames.frame.229.pkt_pts=2438664735, frames.frame.229.pkt_pts_time=27096.274833, frames.frame.229.pkt_dts=2438664735, frames.frame.229.pkt_dts_time=27096.274833, frames.frame.229.pkt_duration=3600, frames.frame.229.pkt_duration_time="0.040000",...

Invoking shell scripts on Windows under MSYS using Command

path,command,rust,msys
I am trying to invoke commands in Rust (1.0 beta 3) on Windows 7 in an MSYS2 environment, but I cannot understand how to do it. Suppose that you have this very simple script called myls in your home folder: #!/bin/bash ls And now create a simple program in Rust...

Visual Studio set command arguments

c#,c++,visual-studio,debugging,command
I'm using Visual Studio 2013. Now, I have a few C# and C++ projects in a solution. Under project properties I can add some debugging properties. That works fine. But when I run the visual studio solution on another computer the command arguments are deleted. How can I define default...

Command filtering

c++,parsing,command,bots,irc
Currently writing an IRC bot for fun and I have some trouble setting up the bot to listen to my commands. ( Works for !quit but not for !join or !leave ) void onPrivMsg(IRCMessage message, IRCClient* client) { // received text std::string text = message.parameters.at(message.parameters.size() - 1); if (text[0] ==...

Whats the difference between “echo” and “!echo” in bash?

linux,bash,terminal,command,echo
What the difference between the command echo and !echo? I think that with !echo it concatenates with the previous command but I'm not sure....

Failed to logout of iscsi target using iscsicli TargetLogout in Windows

windows,command,iscsi
I used iscsicli commands to configure the iscsi configuration for windows. When i logged out of target, it is happening successfully. But when i am rebooting my system again i can see those previously configure iscsi details. And also i am not able to use the "RemoveTarget" or any "persistant"...

Convert TextBox string to parameters

vb.net,command
How would I convert a string from a textbox to multiple parameters/arguments and store them in an array? For example, if I was to write a command in the text box saying "setPosition label1 100 200" then this would convert this into 4 different things: The "setPosition" part would be...

using tar command to create a compressed directory with date

shell,command,ubuntu-12.04,tar
I need to run this command in ubuntu 12.04 32bit tar -zcvf $ BACKUP_DIR/backup_`date "+% d-% m-% Y"`.tgz $HOME/tmp but I can't obtain the directory with date. When I execute the command the shell returns date +%d -%m -%y: the order is not found tar: Eliminating the `/ 'initial of...

Responding to Multiple Command Line Prompts

command,exe,dos
I have an exe that runs though Windows Console and prompts for responses for three questions. I created a batch file to contain criteria and would like to automate all three responses to the questions so selecting the bat file runs the data within the batch file. I need to...

Binding a button to both a function and close event wpf

c#,wpf,button,binding,command
I have a UserControl which is binded to a ViewModel class. I also have a class which contains a Command for closing a window. In my UserControl I have two buttons: Save and Cancel. My Cancel button is binded to the CloseWindow Command and when I click it, the UserControl...

Node.js - Call a system command or external command

javascript,node.js,shell,command
I've an issue with Node.js. With Python, if I wanted to execute an external command, I used to do something like this: import subprocess subprocess.call("bower init", shell=True) I've read about child_process.exec and spawn in Node.js but I can't do what I want. And what's I want? I want to execute...

Debugging at IntelliJ IDEA 14.1.3

debugging,intellij-idea,command
I am curious how to execute previous line of code while debugging? Currently, I see the following buttons: - Step over; - Step into; - Force step into; - Step out; but no button "Step previous"....

Linux command for extract file names in mutiple directories

shell,command
I have multiple directories with identical suffix containing the same file name. Let's say I have files like below. ~/test/sample1/test.txt ~/test/sample2/test.txt ~/test/sample3/test.txt ~/test/sample4/test.txt What I'm trying to do is simply print the list of the paths and file names into a txt file, so I tried.. for t in ~/test/sample*/test/txt;...

Laravel 5 Commands - Execute one after other

laravel,command,queue,laravel-5
I have a CustomCommand_1 and a CustomCommand_2. Any way to create a pipeline of commands and executing CustomCommand_2 right after CustomCommand_1 execution? (without call a command inside the other one)....

Command to replace string in a file

string,replace,sed,grep,command
I want to replace a string in a file using command, but the thing is the string is such "https": false, I want to change it to "https": true, and vice versa. is there any way to accomplish this thru command? Am developing auto script so whenever a user logins...

Print lines that contain a string only once

linux,grep,command,uniq
For example this is my file called Weapons: Sword of Dragons Staff of Fire Bow of Noxious Staff of Light Bow of Noxious I want to type in a command that will display lines containing Bow only once. Here is what I tried: grep -n "Bow" Weapons But it only...

Execute build file for Teamcity locally

deployment,msbuild,command,teamcity
I'm going through the tutorial from this website which explains how to use a custom MSBuild script (*.build). Because I'm new to this topic my question is how I can locally test the custom MSBuild script without Teamcity/VCS. Knows anyone the command for the command line? Or isn't that possible?...

Using FINDSTR to search for a pattern and assign it to a variable

batch-file,command-line,command,dos
I have the following entry in the file Build.aip. I need to write a batch file that searches for "PackageFileName and prints the value assigned for that in the file. In this case, I need to print MyPackageName on the console: <ROW BuildKey="DefaultBuild" BuildName="DefaultBuild" BuildOrder="1" BuildType="0" PackageFolder="C:\Build\Build.aip" PackageFileName="MyPackageName" Languages="en" InstallationType="4">...

Override Symfony\Component\Console\Commande\Command.php

symfony2,console,command,override
I am developping some kind of cronjob monitoring on our symfony2 application. I created a CommandExecution entity with a 'completed' property. I'm using console events to create and persist this entity. My service : kernel.listener.console: class: Evo\CronBundle\EventListener\ConsoleListener arguments: [@doctrine.orm.entity_manager] tags: - { name: kernel.event_listener, event: console.command, method: onConsoleCommand } -...

How to get output of ping command without Ping statistics?

windows,command,ping
For example, in Windows 7 output of command ping -n 1 ::1 is following: Pinging ::1 with 32 bytes of data: Reply from ::1: time<1ms Ping statistics for ::1: Packets: Sent = 1, Received = 1, Lost = 0 (0% loss), Approximate round trip times in milli-seconds: Minimum = 0ms,...

Execute linux shell command using PHP script and display in browser?

php,linux,shell,browser,command
Executing unix shell commands using PHP Running shell commands using PHP script Execute a shell command through php and display it in browser? I have already referred to the above links. But, I'm experiencing an issue in displaying the linux shell command process in the browser. My linux command: top...

How dose the command line prediction work in typical routers?

command
Anybody, who does some command in typical routers like cisco or junper, would know when you type commands, there is 'tab completion' for every level of one command, and if you type '?', you also can see the possible options. How do they implement it? I want to make a...

Python capture command send to unix, capture output and write to file [closed]

python,file,unix,command,output
import subprocess cmd = 'ifconfig -a' p = subprocess.Popen(cmd, shell=True, stderr=subprocess.PIPE) while True: out = p.stderr.read(1) if out == '' and p.poll() != None: break if out != '': sys.stdout.write(out) sys.stdout.flush() <<<HOW TO CMD SENT AND IT'S OUTPUT>>> file = open('outputFile.txt', 'w+') file.write(out) file.close() ...

Run a Curl comand from a jenkins job

shell,curl,groovy,jenkins,command
can anyone tell me how we can run a curl command from jenkins. I'm on windows 7 and i'm trying to put .sh on artifactory from a job jenkins. thanks

How do I get python to fetch information from command prompt such as 'tasklist'

python,command,windows-8.1
I want a program in python that can get a list of all of the programs running, like all the .exe's, and I want to be able to get them into a variable or array so that I can maybe use a for loop to go through them and filter...

Having troubles with a command's execution

c#,command
So, basically what I'm doing is, after adding a diagnosis on the TextBox I'm checking if there is a Diagnosis with the same name already. The connection works fine, however, I'm having difficulties with executing the command in this line here: var count = (int)cmd.ExecuteNonQuery(); Here's the full method protected...

PDFTK and PHP exec

php,shell,command,pdftk
My question is, for some reason when I execute the pdftk command to fill a form through PHP, I get an error from pdftk that it can't find the file. I copy the command and paste it on the terminal and it works fine. I am using full paths for...

What does this ps command do on Linux?

linux,unix,command
I try to get the output of the top 5 processes in a Linux system. I'm expecting to get the percentage of processor (CPU) used but I'm a little worried about if the command that I'm using gets the CPU or the RAM; what is the output? ps -A --sort...

how to combine the elements of a list representing the elements of a Bash command to a new list featuring the equals symbol

python,list,command,arguments,equals
I have a list like the following: commandOptionsAndArguments = ['myBigTool', '--num-callers', '30', '--leak-check', 'full', '--tool', 'memcheck', '--suppressions', 'etc/valgrind-root.supp', '--suppressions', 'Gaudi.supp/Gaudi.supp', '--suppressions', 'oracleDB.supp', '--suppressions', 'valgrindRTT.supp', '--suppressions', 'root.supp/root.supp', '--mySpecialFlag', '$(which python)', '$(which athena.py)', 'athenaConf.pkl'] This list consists of elements of a Bash command featuring options and, if they have them, their respective...

Create text file using echo in command prompt

command-line,command,echo,command-prompt
I'm creating a hello_world.txt in the desktop using echo in command prompt and this is my input. echo hello world > C:\Users\user\Desktop\hello_world.txt The first code works, then I try %userprofile% if example, I want to give it to another user. echo hello world > C:\Users\%userprofile%\Desktop\hello_world.txt Doesn't work. Any simple echo...

Is it possible to call multiple command handlers, when a command is dispatched in laravel

events,laravel,command
I have to call multiple commands handlers when a command is dispatched, I know we can use Events to handle multiple event handlers. I want to whether it is possible to have multiple command handlers for a command in Laravel....

Proper using of MVVM and Commands

c#,wpf,xaml,mvvm,command
How to use ICommand interface with MVVM? In view I add DataContext (which is my ViewModel : INotifyPropertyChanged) and I bind control's property - IsInterminate of progress bar - to property of my ViewModel. This property of my ViewModel isn't static, so I need instance of ViewModel. My questions is:...

SSH remote command

ssh,command,remote-access
I have a strange SSH problem. If I run this ssh [email protected] 'md5sum file.txt' I get back the result as expected, but if I run this ssh [email protected] 'cat file.txt' then it just sits there....

How to join output of two commands in one line?

windows,batch-file,command
For example, following commands (in Windows 7): date/t>>t.txt time/t>>t.txt create following lines in t.txt: Fri 06/12/2015 01:37 PM Is it possible to join output of two commands (see above) in one line (see below)? Fri 06/12/2015 01:37 PM The above mentioned goal can be reached by command: echo %date% %time%...

How to create a custom bash command in linux

linux,shell,command
The question is about bash shell commands in ubuntu 10.04. I have created a simple addition program in c and it works fine in my terminal. Now I want to make this program to execute into my terminal as a command. How can I convert a C program into a...

Dynamically creating operations and services in ServiceStack

c#,api,command,servicestack,cqrs
I'm working on a ServiceStack project that requires me to gather a list of commands, of which I have over 200, and create a operation and service for each of them. Essentially I am making a Commanding API which will allow users to send commands without using the UI (exposing...

Application of sed command several times on a file

bash,file,sed,process,command
I want to apply several times this sed command to a file: sed '1~2d' file.txt>file1.txt let's say I want to do it 4 times, is there a way to do this process getting also the intermediate files? Thank you in advance Best Regards (The files are 1m UTM coordinates and...

Splitting a text line into separate lines from command line

text,split,command
What are some simple options to split a single text line into separate based on a character or pattern? I would like to do this from the command line. An example would be when you want to inspect the PATH. With a single simple command I'd like to split something...

linux command produce Python OSError: [Errno 2] No such file or directory

python,linux,shell,networking,command
I have a problem... import sys import subprocess subprocess.call(['traceroute -I www.yahoo.com']) and I had try import sys import subprocess subprocess.call(['/usr/sbin/traceroute -I www.yahoo.com']) why I am recieving the following error message: "OSError: [Errno 2] No such file or directory". Can anyone help...thanks!...

How to run python script with Laravel's command fire method?

php,python,laravel,console,command
I have a need to execute a Python script from a Laravel Command, but I can't find any methods in Illuminate\Console\Command to complete my task. I want to run this command via the console: C:\Python34\python H:\myapp\app\python\questionPopulator.py To do so, I tried the following in my commands fire() method: public function...

passing the result of a command to SED

shell,unix,awk,sed,command
I want do to the following, get the host ip of my server and then use this value to substitute a dummy value in a config file. For step 1 to get the server ip I call: hostname -I | head -n1 | awk '{print $1;}' For step 2 to...

Batch command and error handling

batch-file,error-handling,command
I am using this code in a batch file: for /f %%f in ('"net user %user% /domain | findstr /i %group%"') do set /a i=%i%+1 It looks like no matter what %user% you type in it will still set %i%+1 equaling 1... even if the %user% is not found. If...

How to copy files and add prefix at the same time?

osx,bash,terminal,command
I am not familiar with osx terminal command. I have a java project containing many package. Some classes have same name in different package. I need to copy all of the class files into a directory, so I need to add corresponding package prefix on each files. For example, I...

composer is not updating for laravel command “simplesoftwareio/simple-sms”: “1.1.*” after adding in composer.json

php,json,laravel,command,sms
I want to integrate SMS plugin in my site. I added the command in composer.json "simplesoftwareio/simple-sms": "1.1.*" after adding i update the composer, following response is get. I am using Laravel 4.1* version. Please suggest for this one. Loading composer repositories with package information Updating dependencies (including require-dev) Your requirements...

Java, need help creating a method to select a specific element in an array

java,arrays,select,command
I have several commands created to ask a user to add numbers to an array. I now need to be able to have the user select a specific element in the array and place an * on the selected element when printed out. I have the program separated into two...

Python - Optional Command Line Argument

python,list,command,arguments,line
I would like to have an option -n, that will allow users to specify a size of a list. The default will be 30. So: ./findNumberOfPlayers.py -n10 I haven't done any command line arguments with python before but am confused with how to include -n10 within the program. I understand...

Are these two python for-loops the same thing?

python,loops,for-loop,dictionary,command
I'm going over a video tutorial and I was caught off guard with a for-loop being in a dict() command. I had a hard time googling things on the dict() command (kept getting definitions on dictionaries and not the command) so I'm now assuming I can add for-loops into commands....

Is there any way to use some “shortcut” for longer command lines?

command-line,command,conemu
I am using the same, longer command line with some arguments every day and it would be nice, if there were some possibility to make some shortcut for it. Is there any?

Copy a file with a name that follows a pattern

linux,shell,command,cp
I need a linux command to copy a file which has a name that matches a certain pattern. For example: I have a file builds/myApp_v_4.1.apk and I want to copy it to artifacts/myApp_v_4.1.apk However it can be myApp_v_4.2.apk or myApp_v_4.3.apk ... So I'm looking for a way to copy the...

PredictionIO: Pio command not found after install

bash,command,predictionio
I am guessing that somehow PredictionIO didn't setup the path variables properly. I used method 2 to install PredictionIO from this link here: PredictionIO Everything installed correctly but when I typed in pio it says command not found. This is what I see: When I try to start pio from...

Java execute multiple console commands on loaded program

java,console,command,runtime,execute
I want to load a program from the console and then execute commands on it later on. The loading works fine, but how can I execute commands on the loaded program without starting it every time I want to use it? For example: ./randomapp command1 command2 But on Java, I...

How to detect whether the command output is being used in unix pipe

mysql,unix,command,pipe,output
In MySql -e option prints different formatting when used the output with pipe. Without Pipe [[email protected] commands]# $MYSQL_CONNECT_STR -e 'select 0/8' +--------+ | 0/8 | +--------+ | 0.0000 | +--------+ With Pipe -- no formatting. [[email protected] commands]# $MYSQL_CONNECT_STR -e 'select 0/8'| more 0/8 0.0000 How the mysql command detecting that...

Java Invalid escape sequences

java,command,exec,command-window
I have this error : "Invalid escape sequences (valid ones are \b \t ..." in my code Java. I make in my code.java : ... r.exec("cmd /c D:\Doc and Settings\USER\Bureau\Apps-Two.loc.nal"); ... The problem is the escapes. How resolve this problem ? Thank you...

How to run one command on multiple terminals?

python,shell,terminal,command,conemu
I am using ConEmu windows emulator and I would like to run one simple command on more terminals at the same time. Is there any way to do that?

Use variables in batch to perform a command with varying inputs

variables,batch-file,command,system
How do I make a variable work in a batch command? I want to do the following: @echo off set /p Name=Choose your name: set /p PW=Choose your password: Net user %Name% %PW% /add I just get "System Error 5" ...

Which is the command in crunch tool in order to create a password list with dates (dd-mm-yyyy)? Starting 01-01-1000 ending 31-12-3000

command,kali-linux
Which is the command in crunch tool in order to create a password list with dates (dd-mm-yyyy)? Starting 01-01-1000 ending 31-12-3000. I tried crunch 10 10 -d 1 -t %%-%%-%%%% but the file is enormous. thank you in advance....

Android Dev - Run top command output to TextView

android,android-asynctask,textview,command,output
I have been reading a lot this forum , and it help me a lot to setup my application , however , I do have another problem now , what I am trying to do is to display the "top" command output in a textview. So layout is basically two...

Slicing with sed

bash,shell,command,slice
I have a file named servers.txt which contains Mysqlserver=172.15.23.23 How can I slice out the IP after the '='? This didn't work: cat servers.txt | sed =* ...

What does “cat -A” command option mean in Unix

linux,shell,unix,command
I'm currently working on a Unix box and came across this post which I found helpful, in order to learn about cat command in Unix. At the bottom of the page found this line saying: -A = Equivalent to -vET As I'm new into Unix, I'm unaware of what does...

Dart, NoSuchMethodError: method not found: 'options' when using CommandRunner

dart,command
Using the example here: http://www.dartdocs.org/documentation/args/0.13.0/index.html I'm trying to write a command line app, but I get NoSuchMethodError: method not found: 'options' when I try to use this example code. Why isn't options defined for the Command subclass instance? If I'm not supposed to use options then what am I supposed...

commands in tkinter when to use lambda and callbacks

python,lambda,tkinter,command
I'm confused as to the difference between using a function in commands of tkinter items. say I have self.mb_BO.add_radiobutton(label= "Red", variable=self.BO, value=2, command=self.red) what is the difference in how the add statement works from this: self.mb_BO.add_radiobutton(label= "Red", variable=self.BO, value=2, command=self.red()) where func red(self) changes the color to red. And self.mb_BO.add_radiobutton(label=...

Why aren't my commandline arguments being read?

c++,command,arguments
I am calling this in my program: std::string gameDirectory = ""; for (int i = 1; i < argc; i++) { if (argv[i] == "-game") gameDirectory = argv[i + 1]; } if (gameDirectory == "") exit(0); With the commandline argument -game demo and it refuses to set the gameDirectory. Any...

BASH command - using IF - FI within a DO - DONE

bash,command
I'm trying to run a command that would find PHP files that contain "base64_decode" and/or "eval", echo the file name, top three lines, if the file contains more than 3 lines, also the bottom 3. I have the following at the moment: for file in $(find . -name "*.php" -exec...

Installing software using command line silent mode

batch-file,azure,command,windows-installer,installer
I am creating batch file to run on azure worker start up task to install GPG software on windows 8 in silent mode or quiet mode -don't want to see UI dialogs how to pass installation folder or other parameters in command line I have tried using below line but...

Using Jmeter OS Process Sampler to collect script data

python,command,jmeter
Is it possible to collect the output of a python script using the "OS Process Sampler"? My python script does a database query and returns "r1=123 r2=456 r3=789" Is there a way to collect the r1, r2, r3 values and graph them?...

mosquitto (on windows) command not found

windows,command,mosquitto
I'm a newbie to MQTT and mosquitto. I recently installed mosquitto on my Windows OS using the Windows binary installation file on the website (http://www.eclipse.org/downloads/download.php?file=/mosquitto/binary/win32/mosquitto-1.4.2-install-win32.exe). However, when I try to run the mosquitto commands, it displays an error saying that the command is not found. Upon Googling this, I found...

Passing in batch file with parameters as parameter in sftp command

batch-file,parameters,command,sftp
I am attempting to automate a upload/download from a sftp depot. The password is piped into the sftp command. I want the batch to execute as follows: batch1.bat: @ECHO OFF SET usernameHost=%1 SET password=%2 SET inputLoc=%3 SET outputLoc=%4 (echo %2) | sftp -b (batch2.bat %3 %4) %1 A batch2.bat will...

Prism Command Binding using Parameter?

c#,wpf,command,parameter-passing,prism
I have a working hyperlink as follow: XAML: <TextBlock > <Hyperlink Command="{Binding NavHomeViewCommand}" > <Run Text="{Binding PersonSelected.PersonKnownName}" /> </Hyperlink> </TextBlock> Constructor: navHomeViewCommand = new DelegateCommand(NavHomeView); Command: private readonly ICommand navHomeViewCommand; public ICommand NavHomeViewCommand { get { return navHomeViewCommand; } } private void NavHomeView() { int val; val = PersonSelected.PersonKnownID); var...

Batch file without error dialog

windows,google-chrome,batch-file,command
I need to create a batch file that run this command start chrome The problem is that I'm not sure that on the machine there is Google Chrome installed. I can't rely on the registry because I will not have admin permissions. If I run this command on a machine...

Shell Script Variable Scope with commnd

bash,shell,variables,scope,command
I came across an interesting thing in Shell Scripting and not 100% sure why the behaviour is like this I tried the below script: #!/bin/sh CMD="curl -XGET http://../endpoint"; var1=eval $CMD | sed -e 's/find/replace/g'; echo $var1; # Output: printed the value on this line echo $var1; # Output: blank/no data...

How do I make a function print out a certain amount of Random numbers through the command line? C

c,random,command,argv,argc
How do I pass an arguement and print that amount of numbers in my program? So far I have found out that if I change count to a lower number than argc, the amount of numbers increases. However, I want it to print x amount of numbers on whatever I...

Run JavaScript in a Windows Command Line

javascript,command,line,cscript
This is something I only found out about today is that JavaScript can be run through a windows command line. So I found out that to run a javascript file in windows cmd.exe you use cscript. My hworld.js file only has one line print('hello world'); I try to run this...

TextBox binding is not working

c#,wpf,binding,textbox,command
I have two UserControls: 1) ContactDetailsView. 2) SearchBarView. In theSearchBarView, I have a Search button, which raises a command when clicked: Command="{Binding SearchCommand}" In the SearchBarView code behind, I have the following code: DataContext = new SearchBarViewModel(); In the ContactDetailsView I have the following code: xmlns:ViewModel="clr-namespace:Accounts_Manager.UserControls.SearchBar" in the definition of...

What is the meaning of -e option in a shell test ('[') command?

shell,command,option
I'm working with shell command in Linux and I found this command: while [ ! -e /tmp/.wm_ready ]; do sleep 0.1 ; done I think this command does sleep 0.1s until /tmp/.wm_ready is created. But I don't know what is -e option. Could anyone help me to solve this?...

BindingResolutionException when using constructor params in Laravel 5 Command

php,laravel,command,laravel-5
I am making a command that is invoked via controller. When I do a simple example command and controller like this, it works: //Controller $command = new TestCommand(); $this->dispatch($command); //Command public $name; public function __construct() { $this->name = 'hi'; } public function handle(TestCommand $command) { dd($command->name); } When I invoke...

Redirect Outward of unix os commands to html page

linux,unix,command
How can i redirect and export unix os commands to HTML Page?

CMD : Merge Files Echo date and file name to merged file

batch-file,cmd,command,command-prompt,text-formatting
I have used the below code to merge .cpp files in a directory.This code was a result of question asked in super user but there are no replies since my question was edited.So please don't mark this question as duplicate . @echo off cd C:\test echo ^<html^>^<head^>^<style^> pre {page-break-after: always;}...

eZ Publish 5 API - CreateContent Command error

php,symfony2,command,ezpublish
I'm trying to create content following this example on the cookbook : https://github.com/ezsystems/CookbookBundle/blob/master/Command/CreateContentCommand.php For the moment i'm just trying to create 'folder' content, i have the following error while executing the script : PHP Fatal error: Call to a member function attribute() on a non-object in /vagrant/application/ezpublish_legacy/kernel/search/plugins/ezsearchengine/ezsearchengine.php on line 53...

Pound sign a bunch of code at once in psychopy for mac

python,command
this is a very basic question, but is there a way to put '#' next to a highlighted bunch of code in psychopy for mac? Edit: if you are using psychopy for mac you can press ctrl-' to input, ctrl-shift-' to remove. ...

MSSQL to VB.NET conversion

sql-server,vb.net,command
I'm working on a projec which is converting T-SQL procedures into VB.NET code and I've been thinking about how to write something neat, clean in VB.NET. For example, this is the T-SQL : insert into X( column1, column2, ....., column100) select column1, column2, ....., column100 from Y How should I...

Electron (Atom-Shell) Run unix command from link in page

javascript,html,node.js,command,electron
I am trying to learn Electron (Atom-Shell) but I am finding it pretty tough to find documentation for it... I am simply trying to figure out how to create a link with <a href="something"></a> in index.html, and have it open a terminal window or run some sort of program. I...

Writing text into and retrieving text from the text file using command line auguments

c++,text,command-line,command,command-line-arguments
Hello I want to write the output of my C++ Program in a text file using Command Line Argument then afterward retrieve it from the file . can you help me please I cannot get a satisfying code help.

Not recognized command everytime in the first line of a code

batch-file,command,line
I have a problem with my BATCH file... Whatever is written on the first line, it says: [command] is not a command. Like so: @ECHO OFF I get this output: [C:\folder (path)]>´╗┐@ECHO OFF ´╗┐@ECHO is not a command It does the same even in a clear batch file(nothing except @ECHO...

Explanation for fvctl command?

command,openflow
I really need your help to understand what the dl_type=0x0800 and the nw_proto=6 mean in this command of flowvisor: $ fvctl -f /dev/null add-flowspace dpid1-port4-video-src 1 100 in_port=4,dl_type=0x0800,nw_proto=6,tp_src=9999 video=7 Thank you!...

Yii - Calling api request within CConsole

api,yii,console,command
I have the following issue: I have a local db with comments and I need to do some actions with some users I'm getting via an API request. Code is something like this: class RunCronCommand extends CConsoleCommand { public function actionIndex() { ... $comments = Comment::model()->findAll('status = :status', array(':status' =>...

Multiple line search in a file using java or unix command

java,shell,unix,command
I want to find the following pattern in a file like subclass "Pool1" 11:22:33:44:55:66 { dynamic; } the above pattern I have to find in a file. How can I find either using java or Unix command?...

How can I run a command line command from within a ruby file?

ruby,file,terminal,command
I have a gem installed that displays a ascii image of a train moving across the terminal screen when someone types "ls". I also have a file called runner.rb. If it's possible, how can I input the "ls" command to the terminal from within the ruby file?...

Set a command to execute on boot + set daily reboot - Ubuntu [closed]

linux,ubuntu,command,server,boot
I have explored options to do both of these, however no definitive method has worked/possible for me to implement. What I want to do is this: First off I want my ubuntu server to restart once a day at a specific time. At boot, I want it to automatically execute...

Implementing ICommand such that only one method may run at a time, others silently fail?

c#,command
I've been trying to implement ICommand in such a way that while the method it is executing is running, all other methods executed with this same type of command will fail (i.e. there is a static IsBusy variable that causes execute to return). One caveat is that the methods passed...

Unix command to find unique Account ids in a unix file

bash,shell,unix,command
My unix file has the below content. How do i find the unique AccountIds? i.e output of below should be: 1, 2 2015-03-06 11:27:13 print log:71 - AcountId: 1 logoutput date 2015-03-06 2015-03-06 11:27:13 print log:71 - AcountId: 2 logoutput date 2015-03-06 2015-03-06 11:27:13 print log:71 - AcountId: 1 logoutput...

How to find only the total RAM in Python

python,linux,shell,terminal,command
I am creating a bunch of Python functions for use in a later script and they find things like free RAM, Total RAM, and RAM in use. I want to only find the number, nothing else. Is there a Python module or something to find only these numbers? I have...

How to schedule commands to run in background in Azkaban

bash,background,command,azkaban
In bash script, I can append & at the end of the command to make it run in the background such as: top & However, when I put that in a Azkaban job, such as: type=command command=top & It will give the error message as: 29-04-2015 23:53:08 PDT start ERROR...

What's the Command to purge/delete all contents in all “public_html” folders?

linux,centos,command,public-html
What's the Command in CentOS to purge/delete all contents in ALL "public_html" folders for all users at once? (I have my web server that I just cloned to make it into a mail server, but I don't want too keep all the public_html files)

Add constraints to the elemets of List

grails,command,constraints
Is there are any possible way to add constraints to the elements of List? For example I have a command which accept List and I want add constraints on this elements, for example on size. class SongCommand { String title List<String> couplet List<String> chorus Boolean isChorus Boolean isChorusRepeat static constraints...

How to use find ,-exec and cp commands together in ruby code?

ruby-on-rails,ruby,shell,terminal,command
I would like to find .plist files recursively in a folder and copy that files into new folder by a single terminal command. find /Users/admin/Desktop/Norton/StaticAnalysis -iname "*.plist" -exec cp {} /Users/admin/Desktop/Test \; This is the command which is working fine in terminal. But i have to use this command in...

How to run remote shell command using python script

python,shell,command,backup
I tried to run remote command to back up my server db, after dumbing it I can't figure out how to remotely get the datas. https://docs.python.org/2/library/subprocess.html Found some documentation, but that didn't really helped me....

Laravel 5 Command Scheduler, How to Pass in Options

laravel,command,queue,scheduled-tasks,laravel-5
I have a command that takes in a number of days as an option. I did not see anywhere in the scheduler docs how to pass in options. Is it possible to pass options in to the command scheduler? Here is my command with a days option: php artisan users:daysInactiveInvitation...

Supress % (percent sign) escaping in a CMD file? (Redux)

batch-file,cmd,command,escaping
After researching, I think I know the answer to this: no. But just in case I am missing something: Is there a way to globally suppress % escaping in a CMD file? Something like: SETLOCAL NOESCAPE MYAPP.EXE "%41%42%43%44" So MYAPP.EXE sees the literal string: "%41%42%43%44" I know I can double...

A python script that activates the virtualenv and then runs another python script?

python,windows,shell,command,virtualenv
On windows vista, I need a script that starts the activate (to activate the virtualenv) script in C:\Users\Admin\Desktop\venv\Scripts\ And later, in the virtual environment, starts to the manage.py runserver in the folder : C:\Users\Admin\Desktop\helloworld\ how should I do? What modules should I use?...