command-line-interface

use angular 2 instead of angular 4 with angular-cli

若如初见. 提交于 2019-12-02 06:13:48
How can i create angular 2 app with angular-cli instead of angular 4? https://github.com/angular/angular-cli my package.json: "dependencies": { "@angular/animations": "^4.0.0", "@angular/common": "^4.0.0", "@angular/compiler": "^4.0.0", "@angular/core": "^4.0.0", "@angular/forms": "^4.0.0", "@angular/http": "^4.0.0", "@angular/platform-browser": "^4.0.0", "@angular/platform-browser-dynamic": "^4.0.0", "@angular/router": "^4.0.0", "core-js": "^2.4.1", "rxjs": "^5.1.0", "zone.js": "^0.8.4" }, "devDependencies": { "@angular/cli": "1.1.1", "@angular/compiler-cli": "^4.0.0", "@angular/language

How to download the app with the CLI from the Swisscom App Cloud?

筅森魡賤 提交于 2019-12-02 04:02:09
I am trying to download my app wich is currently running in the Swisscom App Cloud. Therefore I installed the cf-download plugin. My command: cf download app-name /public --verbose --omit /vendors --overwrite After running this command I get the following error: The app is running on the Diego backend, which does not support this command. Is cf download thus not possible in the Swisscom App Cloud? I've tried cf files as well. Same error. You can do that with an API call Apps API Downloads the staged droplet for an App GET /v2/apps/:guid/droplet/download When using a remote blobstore, such as

How to check if there is a there is a wget instance running

混江龙づ霸主 提交于 2019-12-02 03:47:38
I have this php script that will run wget's fork processes each time this is called with the & : wget http://myurl?id='.$insert_id .' -O ./images/'. $insert_id.' > /dev/null 2>&1 & But how I can check if there is already a wget proces in progress and if there is one, don't run another one ? This code is used to control running process (which in my case is php script). Feel free to take out parts that you need and use them as you please. class Process { private $processName; private $pid; public $lastMsg; public function __construct($proc) { $this->processName = $proc; $this->pid = 0; $this-

Command line interface inside your C# application

浪子不回头ぞ 提交于 2019-12-02 03:36:07
问题 I have been working with C# for a few projects, nothing big or something. So I want to start working on a real project now. I've created a IRC bot in C#. This IRC bot runs without a GUI in a commandline. Now when it runs, it outputs every command and stuff. What i want to do is create a interface for the application inside the commandline. So that im able to type commands into the application and output the results of the command. I've tried reading several topics on multi-threading my

What is the equivalent of sequel pro's just checking “connect using ssl” in mycli?

巧了我就是萌 提交于 2019-12-02 03:27:36
问题 When using SequelPro, I have to check "Connect using SSL" option to connect to a remote mysql database server, but without providing "Key File", "Certificate" or "CA Cert", which is shown as the screenshot below: Is there an equivalent way to do it in mycli? Or just plain mysql command? 回答1: It's the --ssl option, which means "Enable encrypted connection". mysql --ssl A full list of command-line flags for MySQL CLI ( mysql ) can be found here: https://dev.mysql.com/doc/refman/5.7/en/encrypted

How to use PHP CLI in C#

拈花ヽ惹草 提交于 2019-12-02 02:43:48
问题 I'm from China, so my english maybe is really poor. I will try my best to make you understand my question. I want to use PHP CLI in my C# project. I tried code like this Process p = new Process(); p.StartInfo.FileName = "cmd.exe"; p.StartInfo.Arguments = command; p.StartInfo.UseShellExecute = false; p.StartInfo.RedirectStandardInput = true; p.StartInfo.RedirectStandardOutput = true; p.StartInfo.RedirectStandardError = true; p.StartInfo.CreateNoWindow = true; try { p.Start(); p.StandardInput

Command line interface inside your C# application

偶尔善良 提交于 2019-12-02 01:30:12
I have been working with C# for a few projects, nothing big or something. So I want to start working on a real project now. I've created a IRC bot in C#. This IRC bot runs without a GUI in a commandline. Now when it runs, it outputs every command and stuff. What i want to do is create a interface for the application inside the commandline. So that im able to type commands into the application and output the results of the command. I've tried reading several topics on multi-threading my software cause i believe this is needed for me to achieve this functionality. But i dont know for sure. I've

php exec() function and different hosts

我怕爱的太早我们不能终老 提交于 2019-12-02 01:02:05
问题 I have a script that executes a file in a couple of directories down which looks like this: exec("php-cli $file_path > /dev/null 2>/dev/null &"); //php command-line This works on most hosts but some hosts don't like it and it doesn't run, without generating any error. For the hosts that this fails on, i use exec("php $file_path > /dev/null 2>/dev/null &"); //notice the -cli is gone Which works fine. $file_path is the full path to the file being executed /home/blah/path/blah.php How can i make

How to set a default php.ini path for PHP CLI on Windows?

﹥>﹥吖頭↗ 提交于 2019-12-01 23:21:52
Brief introduction to problem: I need to load pdo_mysql to run command php app/console doctrine:database:create and other commands for Symfony2. I found a way to do this by running php -c "path/to/my/php.ini" app/console doctrine:database:create Problem: Since I don't want to add the path to my php.ini everytime I run commands in PHP CLI, where/how can I setup Windows, so that everytime I type php somecommand in console it will load my desired php.ini file? What if you add path/to/your/php.ini to the path environment variable and then just run php -c "php.ini" app/console doctrine:database

Creating waiting/busy indicator for executed process

故事扮演 提交于 2019-12-01 23:20:17
问题 i've program which execute child process like cmd := exec.Command("npm", "install") log.Printf("Running command and waiting for it to finish...") err := cmd.Run() log.Printf("Command finished with error: %v", err) While this command is running it download and install npm packages which take some time between 10 to 40 sec, and the user doesnt know what happen until he see the stdout (10-40 sec depend on the network) , there is something that I can use which prints something to the cli to make