General :: Paste File Content Into GEDIT With Xclip?
Dec 18, 2010I have a file clipboard.txt
I do :
Code:
sleep 10s ; echo "focus on the gedit" ; xclip -o clipboard.txt
is not working.
How to make that possible, how?
I have a file clipboard.txt
I do :
Code:
sleep 10s ; echo "focus on the gedit" ; xclip -o clipboard.txt
is not working.
How to make that possible, how?
If you have the value 100 in File1 and the value 5 in File2, how do you write a script to divide the 100 in File1 by the 5 in File2 in Linux Bash Shell?The operating system I am using is Ubuntu 10 and object is to write a script to accomplish this task.
View 5 Replies View Relatedfavor and let me know how can I copy some text in one file and paste it to another file ,when both of the files are being opened by vi text editor ?
View 7 Replies View RelatedI'm using rhel6. Using File Browser Nautilus 2.28.4 I could easily locate any file I'm interested in by it name. I'd like to use this File Browser to locate the file name based on it content e.g. based on some word in the text file. It doesn't work for me that way ... My question: does Nautilus support the search of file based on it content or only based on the name of the file itself?
View 4 Replies View RelatedI am using GEDIT and I would like to have a shortcut key that allows me to tell GEDIT (on Ubuntu) to force reloading from file system the currently opened file.
How can I do that?
i have a file and i want to change the content of file but i also want that md5sum of that file remains same.
View 14 Replies View RelatedI know GEdit has a bug which prevents it from opening a file with null () characters in it. This is a huge inconvenience for me because I frequently have to open big log files with only a couple rogue 's in them.
Sometimes I just run a quick tr -d '' < file.log > file.log.correct and open the correct file. This is a big nuisance. I would like to have maybe an external tool in GEdit that would execute the above command. I tried writing an external tool action (GEdit plugin) using just:
#!/bin/bash
tr -d ''
Input is "current document", output action is "replace current document". But this isn't working. When I open the file, GEdit shows the familiar red warning; activating the external tool with the warning showing apparently has no effect (I think the script is being called but its input/output are not set).
i recently installed Fedora 14 and when i'm trying to open any file i'm getting this error
[root@blitz Documents]# gedit /home/blitz/Desktop/test
**
GLib-GIO:ERROR:gdbusconnection.c:2270:initable_init: assertion failed: (connection-
[code]....
How to find file by content on linux by command. Example: i want find file contain word "helo" on my computer (OS: LINUX)
View 4 Replies View RelatedHow would i write a script which will add a following content to a file.File Before running script.
Code:
acpi = 1
apic = 1
builder = 'hvm'[code]....
I have a file called foo with a date string in it - and nothing else in the file
2010.01.13-22:28:28
I want to send this file content to date -s command so I can modify using a cron job.
I tried several ways to pipe the file contents to date command but did not work.
I am using find to search for .tgz files modified more than 7 days ago and delete them.find /directory/ -iname backup*.tgz -daystart -mtime +7 -exec rm -rf {} My problem is that find will go through the content of tarball as well and list all content. I want to only search main tarball and delete it if older than 7 days.
View 4 Replies View RelatedIf a file is opened from the common prompt with something like:
gedit somefile &
Is there a way to close somefile while leaving the instance of gedit still open? My idea is that sometimes I will have more than one file open in gedit. I run a script daily that updates to a log file. The log file is then opened and viewed with gedit.
I have the following command that I run on cygwin:
find /cygdrive/d/tmp/* -maxdepth 0 -mtime -150 -type d | xargs du --max-depth=0 > foldersizesreport.csv
I intended to do the following with this command: for each folder under /d/tmp/ that was modified in last 150 days, check its total size including files within it and report it to file foldersizesreport.csv however that is now not good enough for me, as it turns out inside each
/d/tmp/subfolder1/somefile.properties
/d/tmp/subfolder2/somefile.properties
/d/tmp/subfolder3/somefile.properties
/d/tmp/subfolder4/somefile.properties
so as you see inside each subfolderX there is a file named somefile.properties inside it there is a property SOMEPROPKEY=3808612800100 (among other properties) this is the time in millisecond, i need to change the command so that instead of -mtime -150 it will include in the whole calculation only subfolderX that has a file inside them somefile.properties where the SOMEPROPKEY=3808612800100 is the time in millisecond in future, if the value SOMEPROPKEY=23948948 is in past then dont at all include the folderin the foldersizesreport.csv because its not relevant to me.so the result report should be looking like:
/d/tmp/,subfolder1,<itssizein KB>
/d/tmp/,subfolder2,<itssizein KB>
and if subfolder3 had a SOMEPROPKEY=34243234 (time in ms in past) then it would not be in that csv file.so basically I'm looking for:
find /cygdrive/d/tmp/* -maxdepth 0 -mtime -150 -type d | <only subfolders that have in them property in file SOMEPROPKEY=28374874827 - time in ms in future and not in past | xargs du --max-depth=0 > foldersizesreport.csv
I am calling a URL from shell script and passing few argumants,Here i have to pass file content as one argument.How can i pass file content through URL.
eg:
content=`cat /Users/test1.txt`
open http://localhost:8080?filecontent=$content
[code],...
I was having a discussion with someone who asked me whether a Linux OS has to be rebooted when the hosts file is modified. From personal experience, on Windows I change the file but don't reboot and I've seen others do the same thing. I assume Linux has no exception(s), but is there any reason why a reboot is not required (to at least justify my actions)?
View 2 Replies View RelatedI have a .txt-file with ~50.000 lines of numbers, generated by a mathematics program. From this file, I need line ~ 1.100 to line ~16.000 (these lines are always the same btw, this may make the solution easier, dunno) to be copy/pasted to another file, where the lines ~500 to ~15.000 (also, every time the same) should be overwritten by the aforementioned lines...I haven't found or come up with anything that works yet, mostly I find solutions to copy everything from one file to another but I can't find something to specifically overwrite a part of a file with part of another.
View 4 Replies View RelatedIs there any gedit plugin, which expands folders of file browser side pane and shows currently editing file, while user switches between tabs?
View 1 Replies View RelatedI have a file, say abc.txt, whit some text lines.The I have a second file, say 123.txt where at a certain point one can read "WORD".I would like to append the whole content of abc.txt (as it appears in abc.txt) in the line after "WORD".
View 1 Replies View RelatedMy employer issues pdf files with everyones work schedules. I copy the content and save it as plain text in a file called unformatted (hope to be able to automate this step someday). Im working on a SED script that reduces unformatted to only display what I want to see and saves the result in a file Iïve named formatted. After that I have to manually copy formatted and save it with that days date as a filename e.g. 2011-02-25 or whatever day is scheduled in the pdf, for use on a mobile device (Nokia N900). I noticed that the date occurs on certain lines in the file so I added a line like:
sed -n 's/^Date: (201[1-9])/([0-1][0-9])/([0-3][0-9]).*/1-2-3/p' < unformatted >theDate
That creates a file theDate with the date in it that I wish to use as the filename for this particular instance. So I would like to skip the file formatted all together and have the sed- script write to a new file using the content of the Date as a filename, but how do I make that happen? And of course it would be more elegant if I could skip the intermediate theDate file as well.
I wanted to copy one file to multiple new files. I have an idea to write a script and do the operation. But here i m looking for any particular command to do this operation.
View 1 Replies View RelatedI set-up my Sudo it works but when I use Gedit I get the following message
Jean-Luc@localhost:~> sudo gedit /etc/fstab
(gedit:7137): Gtk-WARNING **: cannot open display:
samething with /etc/sudoers
If I use vi it's ok, I can modify and save. In Fedora it run ok, but with opensuse?
I am trying to make wine work for explorer. I followed some instructions on this link [URL] To follow this link, I am supposed to
cd ~/ies4linux/ie6
cp user.reg ~/user.reg.old
gedit user.reg
1st and 2nd line went well 3rd line when I try to execute the command gedit user.reg (gedit:2573): Gtk-WARNING ** cannot open display I then /ies4linux/ie6# ls dosdevices(in blue) drive_c(in blue) system.reg(in white) userdef.reg(in green) user.reg
When scrolling down in nano with keyboard (holding "down" key), nano scrolls several lines at once each time. Is there any possibility to configure it so it will scroll one line each time like gedit does when scrolling in gedit?
View 3 Replies View RelatedI am copying the file form one directory to another directory using shellscript.
Here i want to get the Mimetype/Content-type of the file.
How to i can get the MimeType.
I have never developed and deployed webpages from my Ubuntu-i tried storing and paste files in my /var/www folder since i installed and configured Apach,Php and Mysql---
View 2 Replies View Relatedif it is possible to copy and paste as a symlink.
It seems to me that the only way to create a shortcut or symlink is through the command line. I use KDE.
This was one of the most basic things Windows could do since Windows 95, and is one of the simplest shortcuts I dearly miss since leaving Windows.
Has anyone seen a seamless way to create a symbolic link via a GUI based file manager? I have been using PCManfm because I find it fast, but I can copy the file but paste a symbolic link instead of the actual file.
View 9 Replies View RelatedI can use on the local machine the following command:
Code:
# cat /path/to/file >> /path/to/otherfile
but how it works to write from a local to the existing file from a remote machine?
If i type gedit while as root it give this warningQuote:(gedit:5655): EggSMClient-WARNING **: Failed to connect to the session manager: None of the authentication protocols specified are supportedGConf Error: Failed to contact configuration server; some possible causes are that you need to enable TCP/IP networking for ORBit, or you have stale NFS locks due to a system crash. See http://projects.gnome.org/gconf/ for information. (Details - 1: Failed to get connection to session: Did not receive a reply. Possible causes include: the remote application did not send a reply, the message bus security policy blocked the reply, the reply timeout expired, or the network connection was broken.)And over the time, the paragraph block from GConf Error.... to ...was broken is repeated again and again
View 2 Replies View Related