Sponsored Content
Homework and Emergencies Homework & Coursework Questions How to write script that behaves both in interactive and non interactive mode Post 302344449 by methyl on Sunday 16th of August 2009 05:12:49 PM
Old 08-16-2009
Needs a precise definition of a "C program" file on the OP's server and a good overview of the directory structure and permissions.

The implication is that a non-root users will run a root script which displays the header of each "C program" source under their control and then prompts them to decide whether to delete that program source. Should they provide filename(s) as parameters to the script, the script will then only prompt the user to delete those named files.


(I'm backing off on this one because the requirement is much too vague).
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Interactive Mode?

:confused: Can anyone please tell me how to get into Interactive Mode? (2 Replies)
Discussion started by: Nomad
2 Replies

2. Shell Programming and Scripting

Perl Interactive mode

Hi All, Does perl has an interactive mode like other shell? If there is, can any one show me the equivalent code for the below csh script ? This csh code prompts user for their name and prints the name. #!/bin/csh echo -n "Pls enter the your name: " set name = ($<) echo "You hav... (2 Replies)
Discussion started by: Raynon
2 Replies

3. UNIX for Advanced & Expert Users

SU command in non interactive mode

Can i run the SU command in a non interactive mode. What i want to do is to pass the username and the password as commandline or batch parameters. Please let me if its possible and how to pass them. A sample file will be appreciated. Thanks, (6 Replies)
Discussion started by: rohitag
6 Replies

4. Shell Programming and Scripting

how to write a shell script to login to a system which is interactive.

Can anybody help me to write a shell script to login interactive system once u open a connection using telnet it will ask for USERCODE: PASSWORD: DOMAIN: (1 Reply)
Discussion started by: sudhakaryadav
1 Replies

5. Shell Programming and Scripting

script to non interactive mode

Gud morning everybody, I need small help form you people,Please advice me. I have a utility(adpatch) which takes 10-15 prompts, i want to automate this by calling this utility in shell script. Now my qiestion i want to run the script in non interactive mode. An example. $adpatch... (1 Reply)
Discussion started by: swetham.apps
1 Replies

6. Homework & Coursework Questions

Help with Interactive / Non Interactive Shell script

Q. Write a script that behaves both in interactive and non interactive mode. When no arguments are supplied it picks up each C program from the directory and prints first 10 lines. It then prompts for deletion of the file. If user supplies arguments with the script , then it works on those files... (1 Reply)
Discussion started by: rits
1 Replies

7. Solaris

Doubt in zlogin non interactive mode........

I want zlogin -C as non interactive mode so after booting the zone I created a file sysidcfg in /etc directory of the zone the sysidcfg file info as shown below. system_locale=C terminal=dtterm network_interface=primary { hostname=my-zone } security_policy=NONE... (1 Reply)
Discussion started by: vijaysachin
1 Replies

8. UNIX for Advanced & Expert Users

sudo in non interactive mode

Hi , I login to unix using my id and then do a sudo to execute any programs i want. sudo su - <id> password : xxxxxxx Is there a way to make it non interactive so that i can use it in shell script. (1 Reply)
Discussion started by: ashwin3086
1 Replies

9. Shell Programming and Scripting

SFTPing non-interactive mode

Hi All, I need to sftp without any intervention.(LInux,Ksh) I have tried some ideas listed here...but its not working... Please advise on it. (1 Reply)
Discussion started by: jesu
1 Replies

10. UNIX and Linux Applications

How to write automated interactive shell script?

Hello everyone, I just want to write a shell script for automatic feeding the username and password prompts when running my commands, I tried this one but it did not work. Please help me for any way out. #!/bin/bash #!/usr/bin/expect cd ~/workspace/mimosanetworks_mimosa-nms ls -ltr ... (5 Replies)
Discussion started by: sandy-sm
5 Replies
DPATCH(7)							      dpatch								 DPATCH(7)

NAME
debian/patches/script.dpatch - self applying patch SYNOPSIS
debian/patches/script.dpatch -patch [directory] debian/patches/script.dpatch -unpatch [directory] debian/patches/script.dpatch -pkg-custom [directory] DESCRIPTION
A dpatch is a program that modifies the source tree in a given directory. How it does that is entirely up to the person writing it. It can be a script that calls patch(1) with the appropriate options, a complicated perl script that does some deep magic, or anything else. The only requirement is that it MUST accept the -patch and -unpatch options, followed by the destination (or working) directory, when speci- fied. For the sake of compatibility, the second argument is only present when a working directory was explicitly set with dpatch --workdir. For some of the dpatch(1) features to work, the script should follow a common style: there should be a line near the top of the file with the following format: "filename -- author <email>". And one or more "# DP: description" lines. These will be used by dpatch cat for exam- ple. WARNING
dpatch is deprecated, please switch to the `3.0 (quilt)' Debian source package format instead. See http://wiki.debian.org/Projects/Deb- Src3.0#FAQ for a short guide on how to do it. EXAMPLES
One can find dpatch examples under /usr/share/doc/dpatch/examples/. AUTHOR
This manual page was written by Gergely Nagy. SEE ALSO
dpatch(1), dpatch.make(7), dpatch-edit-patch(1), dpatch-list-patch(1), dpatch-convert-diffgz(1) DPATCH 2 Dec 13 2011 DPATCH(7)
All times are GMT -4. The time now is 09:22 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy