aman_greval
asked on
Error while chech-in
I sent files to the configuration management team to check-in certain files.
They sent me this reply. Can you tell me what is wrong?
The files have been checked in. However conk_prod.sql could not be checked in and encountered following error.
"ERROR [/home/nims/source/SCCS/Re lease223/c ongo/produ ction/s.co nk_prod.sq l]: No newline at end of file 'conk_prod.sql' (de18)
dev.sh: Failed during delta""
They sent me this reply. Can you tell me what is wrong?
The files have been checked in. However conk_prod.sql could not be checked in and encountered following error.
"ERROR [/home/nims/source/SCCS/Re
dev.sh: Failed during delta""
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
You needs to look at how conk_prod.sql is created; If it's created by vi for example, vi will always append a newline character at the end of the last line, even if you didn't type <Return>. But if it's generated by a program, e.g.
printf "sql statement" > conk_prod.sql
there may not be a newline.
A simple way of fixing text files might be:
for FILE in *.sql
do
echo "" >> $FILE
done
(Even though we're appending "nothing" to the file, it creates the newline at the end. But _please_ make copies of your files first, in case this breaks them.)
printf "sql statement" > conk_prod.sql
there may not be a newline.
A simple way of fixing text files might be:
for FILE in *.sql
do
echo "" >> $FILE
done
(Even though we're appending "nothing" to the file, it creates the newline at the end. But _please_ make copies of your files first, in case this breaks them.)
ASKER
We do not get such errors everytime we check-in our files. Why did we encounter this error this time.
Please tell me what precautions we should take (during check-in) so that this error is not repeated in future.