Hi,
does anybody knows about wc -l, how to transform it inot a just number?
this script ALWAYS executes the command3!!, However, the value of BMU_RUNNING is 1
case $BMU_RUNNING in
*0) command1
;;
*1) command 2;;
*)command 3;;
esac
The... (3 Replies)
Hello
im trying to redirect the standard output into txt file but with combination of string
if I do :
date >! foo.txt
there is no problem and im getting the date into the foo.txt
but what should I do if I like to add string in the same command so the result will be in the txt : The date... (2 Replies)
Hi,
Fairly new to unix scripting, hoping to get some help.
using AIX v5
Basically I have 3 files 1). Header record 2). many detail record 3). Trailer record
My desired result is 1 file which contains Heaeder, Detail, Trailer
Currenty I am using a series of:
... (8 Replies)
hello
just i saw a really strange for cat
i have file (file1) contains line /home/rajiv/proj1/*.txt
now applied a commonds
DDPATH="$(cat file1)"
echo $DDPATH
it shows all the txt files in that folder like /home/rajiv/proj1/read1.txt /home/rajiv/proj1/read2.txt... (7 Replies)
Hi All
How can i append a file name with a string
e.g.
Lets say i have a file called
ABC_TEST_1234_1.dat
and i want to append the file name with a lets say 100
so the output file should look like
ABC_100_TEST_1234_1.dat
i have aroung 9000 file in a directory and want to... (3 Replies)
Hello attempting to redirect out to create a startup script in solaris. The steps are working but the $1 entry is being left out. syntax below and content of output file below.
cat > S99build << EOF
> #!/bin/bash
> case $1 in
> 'start')
> /usr/os-buildsol.sh
>
> ;;
> esac
> exit 0
>... (3 Replies)
Hi All,
I'm trying to insert a string into a file at a specific location.
I'd like to add a string after the parent::__construct(); in my file.
<?php if (! defined('BASEPATH')) exit('No direct script access allowed');
class MY_Controller extends CI_Controller {
function... (6 Replies)
Hi,
I need to redirect the output of the file until the first instance of a string is found.
So in the filename output.txt i was to redirect everything from the start to where i find this string "BEA-000377" is found to a new file called output_new.txt
Sample output.txt
the controller... (1 Reply)
I have a directory that is restricted and I cannot just copy the files need, but I can cat them and redirect them to a new directory. The files all have the date listed in them. If I perform a long listing and grep for the date (150620) I can redirect that output to a text file. Now I need to... (5 Replies)
Discussion started by: trigger467
5 Replies
LEARN ABOUT FREEBSD
sem_destroy
SEM_DESTROY(3) BSD Library Functions Manual SEM_DESTROY(3)NAME
sem_destroy -- destroy an unnamed semaphore
LIBRARY
Standard C Library (libc, -lc)
SYNOPSIS
#include <semaphore.h>
int
sem_destroy(sem_t *sem);
DESCRIPTION
The sem_destroy() function destroys the unnamed semaphore pointed to by sem. After a successful call to sem_destroy(), sem is unusable until
re-initialized by another call to sem_init(3).
RETURN VALUES
The sem_destroy() function returns the value 0 if successful; otherwise the value -1 is returned and the global variable errno is set to
indicate the error.
ERRORS
The sem_destroy() function will fail if:
[EINVAL] The sem argument points to an invalid semaphore.
[EBUSY] There are currently threads blocked on the semaphore that sem points to.
SEE ALSO sem_init(3)STANDARDS
The sem_destroy() function conforms to ISO/IEC 9945-1:1996 (``POSIX.1'').
POSIX does not define the behavior of sem_destroy() if called while there are threads blocked on sem, but this implementation is guaranteed
to return -1 and set errno to EBUSY if there are threads blocked on sem.
BSD February 15, 2000 BSD