Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8587137
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T22:29:39+00:00 2026-06-11T22:29:39+00:00

I have this script to open a new console, ssh into a server, run

  • 0

I have this script to open a new console, ssh into a server, run a deploy command.

I pass to the script the version of the deploy

xdotool key ctrl+alt+t
sleep 3
xdotool type "ssh myserver"
xdotool key Return
sleep 10
xdotool type "password"
xdotool key Return
xdotool type "sh path-to-script/deploy.sh $1"
xdotool key Return

I have several problems with this and I allready tried to google for a solution without success.

  • the character / its transformed to an &. when I run the script
  • copy&pasting in the console it works, but no if I run it as a sh file
  • the $1 is not evaluated

Can you give me any pointer in making this work. xdotool is not mandatory, I would use whatever it works

note: I can’t by pass the ssh with a command becouse the security politics of the company and also don’t know how to do it if I can’t the settings in myserver

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-11T22:29:41+00:00Added an answer on June 11, 2026 at 10:29 pm

    Similar problem here:
    http://code.google.com/p/semicomplete/issues/detail?id=13#c29
    Try:

    xdotool type setxkbmap de
    xdotool key Return
    xdotool type "sh path-to-script/deploy.sh $1"
    xdotool key Return
    

    Maybe it works better if you write a script:

    #!/bin/bash
    xterm -e "ssh myserver \"sh path-to-script/deploy.sh $1\"; sleep 5"
    

    and invoke it like this:

    ./theAboveScript.sh &
    sleep 10
    xdotool type "password"
    xdotool key Return
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have this code in userpage.php: <script langauge=JavaScript><!-- function newWindow(fileName,windowName) { msgWindow=window.open(fileName,windowName); } //--></script>
I have this script that run to fix my menu bar to the browser
I using this jquery script to open a dialog on my page. I have
I have this script to read a devices list and send a command. but
I have this simple script: ids=22656 url = http://api.stackoverflow.com/1.0/users/+ids+/timeline; console.log( url ); xmlhttp =
I have made this script to open a fancybox from code behind, but it
I have this script and need to be able to call the $play variable
I have this script set up that echoes all relevant users in a database
I have this script in the head of my index.html. I want different scripts
I have this script: #!/var/home/cherry/opt/perl use Test::More; use DBI; use Test::mysqld; use Data::Dumper; my

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.