I have a leshan server jar file (to which I have made some changes) obtained by running the maven clean install. I specify that I work in linux and I put this jar file inside a “leshan_docker” folder contained in the desktop. within the same folder there is also a dockerfile to build the server im…
Tag: linux
Read a file that’s constantly updated (C++)
Let me start with saying that I’m around 3 days old in C++. Ok to the main question, I have a file that spans multiple lines, and I’m trying to print one specific line repeatedly, which is subject to change arbitrarily by some other process. Example file : I’m trying to print the middle line…
How to get the correct binary for my architecture. Trying to run ARM (.s) files
I’ve used the following commands for cross-compilation on ubuntu to run simple.s but am getting an error The commands are: I tried to obtain the binary’s architecture by and my machine’s architecture by and found that they were different. I believe getting the right binary for the architectu…
Bash script return to menu if status code inside of a while loop [closed]
Closed. This question needs details or clarity. It is not currently accepting answers. Want to improve this question? Add details and clarify the problem by editing this post. Closed 2 years ago. Improve this question I’m doing a bash script to check cryptocurrency prices, and it updates in a while loop…
How can I build a Trap function with any key
This function exits my script when I press cntr+C, how can i modify it to make it works when I press enter? Answer This might help:
extract substrings starting with same pattern in a file
I have a fileA.txt which contains strings: I would like to extract all the substring which start with RS Output: I tried something like this: However I only get the first string RS0247 printed out when I do echo Answer Given the three sample lines pasted above in the file f… Assuming a fixed format: Ass…
Running LISP code via CLISP on Linux (Ubuntu WSL)
I am new to LISP and was wondering how to correctly run a simple lisp program on Ubuntu Linux. Currently, I have a LISP file called “intmax.lisp” that contains the following code: (defun intmax (x y) (if (> x y) x y)) However, when I go to the command line and run: clisp intmax 2 4 To compare 2…
Ethtool Structs elements and what are they. What settings and info defined on them
I am reading driver code from Intel E1000E AND Realtek r1869 driver. I hvae the devices for both, Currently I am studying ethtool_ops. I know Ethtool can be a tool for Long story short, ethtool is a means to display and adjust generic NIC/driver parameters (identification, the number of receive and transmit q…
How can I cause a “initscr” break with ncurses?
I know this is a weird question, but I want to get the “initscr” function error mentioned by the doc (getting invalid pointer and an error message on stderr) to test if a wrapper works properly. But I don’t find any information about that. I’m currently working with ncurses 6.2. After …
Name check match pattern
I need help as to why code B is producing a different result The code below (CODE A) produces the correct output (match) However, the below (CODE B) produces a wrong output (no match) Answer To check a regex in an if-statement you’ll need to use =~ instead off ==; Both will match as expected. Try it onl…