Everytime I give the command for any package, in this case for ggplot2, I get this after a few minutes. I am missing something, but can’t figure out what. Thanks in advance! Answer You are on R 2.14. Please please PLEASE upgrade to something from the last few years — preferably from the current ye…
Bash – Move last word in line to beginning of line
I need to move (in a text file) the last word on a line to the beginning of that line. From This: To This: Answer With GNU sed: Output: (2007) I Am Legend (1987) RoboCop (2001) Shrek To edit file “in place”:
How is the code segment shared between processes in Linux?
I have read about the copy-on-write principle which occurs when a new process is being forked in Linux. I have also read about the fact that if multiple instances of one program are running at the same time, only one instance of the program code can be found in the memory. I was wondering whether this is a di…
Simulate VPN connection in docker
I want to simulate a VPN traffic on my machine. I’ve set up VPN server which runs inside a docker image. I can successfully log in. The problem is that the docker image is running on my machine on the default docker’s bridge – docker0. There is no change if I do connect to machine using VPN …
How can I read the files from a tar command into an array using BASH?
Using a BASH script, how can I execute a tar command and read the output (the list of files) into an array? I’ve tried a number of things, including: I’ve tried with and without the backquote (grave accent) and I’ve tried using t as an option on the tar.gz file. I was trying to accomplish th…
Getting a pipe status in Go
I’m unable to get a pipe state in Go (1.5). While writing on a mkfifo created pipe, I try to get the state of this output pipe: using the Write return status EPIPE using the Write return status EPIPE and signal.Ignore on SIGPIPE (just in case) using signal.Notify on SIGPIPE I can see that: EPIPE is neve…
/bin/sh: 1: arm-linux-gcc: not found on ubuntu
I m trying to build using gcc arm cross compiler and i get following error Building file: ../src/application.c Invoking: GCC C Compiler arm-linux-gcc -O3 -Wall -c -I -fmessage-length=0 -MMD -MP -MF”src/application.d” -MT”src/application.d” -o “src/application.o” “../s…
What’s the easiest way to use the output paths from a git command in a subsequent git command?
I far too frequently use the mouse to do things like this: I know that some git commands accept wildcards, and this mitigates this problem somewhat, but I’m wondering if there is a way do specifically reference pathspecs, etc. from previous commands. How can I run commands like this without using the mo…
How to make pipe run sequentially
Specs Don’t think this should make a difference but I’ll include it anyway GNU bash, version 3.2.51 Premise So say i have a pipe with multiple parts, how can I prevent part of the pipe running before the previous part is finished. Example In the below examples I will try to display the issue Outpu…
QT Creator’s code completion for function overloading is buggy
I am using QT Creator on Ubuntu 14.04, to make a C++ project using cmake (not using qmake). In my source code editor, if I type a function name that is recognised, then next to the function name a code completion box will appear. This box consists of a down arrow, and next it the function prototype. Now, it s…