• The following will deploy service on remote machine. Before deployment it will check if the service is running, and if so, stop it. After deployment it will create or update the service and start it.

    C:\Program Files\IIS\Microsoft Web Deploy V3\msdeploy.exe

    -verb:sync -source:dirpath=$(System.DefaultWorkingDirectory)/MyBuild/artifacts/MyService
    -preSync:runCommand=”powershell if (($s = Get-Service MyService -ea ignore) -ne $null)
    { Stop-Service $s } ”
    -postSync:runCommand=”powershell $name=’MyService'; if (($s = Get-Service $name -ea ignore) -eq $null)
    { $cmd = ‘create’ } else { $cmd = ‘config’ };
    sc.exe $cmd $name binPath= ‘$(TargetDeployPath)\MyService\MyService.exe’ start= auto ;
    sc.exe description $name ‘Deployed by Release Management'; sc.exe start $name “

  • After publishing Ionic starter to Heroku, the repository was empty. Cloning the code from Github, modifying the code, and then publishing to Heroku worked.

    C:\bg\heroku>git clone https://github.com/driftyco/ionic-heroku-button.git
    C:\bg\heroku>heroku git:remote -a ionicist

    Ionic Starter on Heroku

  • Силовой жонглер Вячеслав Анохин (Juggler Vyacheslav Anokhin)

    He lives in Atlanta GA now.








  • The script can deploy the web application or windows service.


    $h = hostname
    $me = whoami

    Write-Host “command path:” $PSCommandPath
    Write-Host “host:” $h
    Write-Host “as:” $me
    Write-Host “from:” $source
    Write-Host “to:” $dest

    $dir = Get-ItemProperty “Registry::HKLM\SOFTWARE\Microsoft\IIS Extensions\MSDeploy\3″
    Write-Host “path from registry value:” $dir.InstallPath
    $msdeploy = “{0}msdeploy.exe” -f $dir.InstallPath

    if (!(Test-Path $msdeploy)) {
    Write-Host “path from registry 32 value:” $dir.InstallPath
    $msdeploy = “{0}msdeploy.exe” -f $dir.InstallPath_x86

    & $msdeploy -verb:sync -source:$source -dest:$dest -setParam:$parameters

    PowerShell command (assuming the script saved as deploy.ps in app-sample folder.

    Note: quotation marks around parameters

    PS C:\dev2\app-sample> .\deploy -source dirpath=c:\dev2\app-sample\My.Backend\bin\release\ -dest dirPath=c:\xyz -parameters "kind=XmlFile,scope=.config$,match=//appSettings/add[@key='SomeSetting']/@value,value=some-value"

    post more: https://www.regmagik.com/wp-admin/post-new.php

  • How to deploy web application automatically?

    msdeploy -verb:sync -source:package=”C:\MyPackage.zip” -dest:iisApp=”Site1/App1″

    The site Site1 must exist. The package can be created as part of the build and published as artifact.

    Alternatively, one can publish a site without creating a web deploy package.

    msdeploy -source iisApp=$(System.DefaultWorkingDirectory)/Solution/drop/MyWebApp/_PublishedWebsites -dest “iisApp=$(MySiteName)\$(MyAppName),computerName=$(Machines),userName=$(ServerAdmin),password=$(ServerAdminPwd)”

    Depending on environments, one method may be faster than another.

    Using Parameters

    msdeploy -source iisApp=$(System.DefaultWorkingDirectory)/Solution/drop/MyWebApp/_PublishedWebsites -dest “iisApp=$(MySiteName)\$(MyAppName),computerName=$(Machines),userName=$(ServerAdmin),password=$(ServerAdminPwd)” -parameters “kind=XmlFile,scope=web.config$,match=//appSettings/add[@key=’MyKeyName’]/@value,value=$(MyValue)”

    Details about params:

    View parameters supported by existing package
    msdeploy -verb:getparameters -source:package=mediawiki.zip

  • 1. Start using local instances of database server to reduce dependency and workload on DBA group.

    2.  Start using wiki to record the tribal knowledge so that it is easily accessible when needed.

    3. Start using concrete scenarios as part of functionality stories so that a developer can write a unit test for the story.

  • How to hide all existing comments from WordPress blog posts? WordPress allows you to delete comments with bulk actions, but if you have many existing comments and want to hide them, you may need a better way to do it.

    The standard WordPress administration UI does not provide a single command to delete all existing comments. But since it stores all comments in the database, you can run a simple SQL query to manipulate your data.

    I used phpMyAdmin and ran SQL update query that marked all comments as unapproved. Then they disappeared from all posts.

    Here’s the query:

    UPDATE `wp_comments` SET `comment_approved`= 0

    In order to run a query, you need a tool and credentials: database name, login name and password. They should be available in your web site hosting configuration.

  • The phone has cracked screen and does not boot up.

    The phone model is Sprint SPH-L900



    HEX 990 002 090 821 67

    DEC 256 691 456 900 532 839

    Owner name Fiona.

    Downloaded touch recovery from here:


    Download Philztouch Recovery

    Start device in download mode.

    The phone appears to have problems with the Screen in Download mode does not show anything, but it does go into download mode after Volume Up confirmation.

    Connect to Odin 1.85.

    The phone appears to have problems with the USB port. The cable has to be held in a slightly out position in order to connect to Odin. Added/Removed messages show up if the cable is not inserted correctly.

    Flush using Odin 1.85

    The device automatically restarted and installed Philztouch.

    The device restarted and showed Samsung Galaxy Note 2 screen, but then it died.

    The battery seems to be bad too. It discharges very quickly.

    Leave the phone charging without turning it on.

    The phone does show the Battery image, but it does not display “charging” animation.

    Tags: ,