Skip to main content
Filter by
Sorted by
Tagged with
-1 votes
0 answers
45 views

I have a file with some strings like below for which I want to replace the || with newline using powershell 5.1. This is || some test || string I've follow some advices in this thread and I'm trying ...
Rasec Malkic's user avatar
Advice
0 votes
0 replies
40 views

I'm building a hobby chess engine that communicates through the UCI protocol. This is communication done through standard out/in of the program, with each line representing a single command. One of ...
Kyle Pollard's user avatar
  • 2,362
2 votes
2 answers
165 views

See the following: Case 1: Hi\nHello Case 2: Hi Hello Both of them are found in text files. So, I did some experiments on them to figure out if there are any differences between them: In [1]: print(&...
hafiz031's user avatar
  • 2,954
4 votes
2 answers
135 views

Demonstrate the issue Let's use nvim to create a text file: > nvim C:\temp\in-file.txt The contents of the text file: > Get-Content C:\temp\in-file.txt abc bcd cde Now let's create a simple ...
dharmatech's user avatar
  • 9,739
2 votes
2 answers
115 views

I'm trying the the Rust version of coreutils on my Windows 10 system. I renamed coreutils.exe to co.exe so that I can type less. od is the Windows version of the Linux command od [from linux man site =...
Just a learner's user avatar
1 vote
0 answers
87 views

Using PhpWord in my PHP project gives me issues. I do have a variable containing CR/LF (\n) and HTML code. Something like: $str='<div style="font-style: italic; text-align:center">...
OfiserChris's user avatar
1 vote
1 answer
123 views

I am newer at coding and can't wrap my mind around what I'm doing wrong. This function takes in text from pdf's and starts collecting text only after a certain "search phrase" is found. Then ...
Sophia's user avatar
  • 19
0 votes
3 answers
270 views

Assume an XML node such as this: <Person> <DOB>11181928</DOB> <LastName>Mouse</LastName> <FirstName>Mickey</FirstName> <City>Los Angeles&...
504more's user avatar
  • 495
1 vote
2 answers
107 views

I am having some trouble with the core.autocrlf feature in Git ... In our team, we are moving from a pure Windows to a mixed Windows and Linux environment (out of necessity). We have a codebase we ...
Joshua Schroijen's user avatar
-6 votes
2 answers
169 views

I want the read function to print anything but the new line when using in Bash script. I tried the following code, but it does not help. It still prints the new line. Minimal reproducing code: #!/bin/...
Sergey Belenkov's user avatar
0 votes
0 answers
118 views

I'm working on a NestJS project on Windows and have configured my environment to use LF line endings globally and in my workspace. However, whenever I generate new files using the NestJS CLI (e.g., ...
Arun Kumar S's user avatar
2 votes
2 answers
149 views

I want my regular expression should error out if my string contains any character other than Alphanumeric. The string should error out if there is a new line character or any white space character in ...
Devashri B.'s user avatar
  • 2,789
-1 votes
1 answer
56 views

Hello i have some logs that are like this DATE-2025-04-10.UTO244234 DATE-2025-04-09.UTO244231 DATE-2025-04-11.UTO244231 DATE-2025-04-06.UTO244222 DATE-2025-04-20.UTO142222 The input i want is DATE-...
Stt4e's user avatar
  • 9
1 vote
1 answer
125 views

I've recently picked up on COBOL coding and have been following Derek Banas tutorial video on it. I decided to test out the IF/ELSE coding on my own, but every time I create a new file and compile it ...
Anna R.'s user avatar
  • 21
0 votes
1 answer
95 views

When I did git diff a b I got: -aaa +aAa^M I became interested. I did hd a and hd b and both show 0d 0a after aaa (aAa), btw editing on Linux in xed for test purposes involved changing one symbol. ...
Martian2020's user avatar
0 votes
1 answer
28 views

Are there any ClangFormat styles (or other tools) which will handle excessive newlines? With two or more newlines after the function parameter parentheses, as in the example below, none of the styles ...
user2023370's user avatar
  • 11.3k
3 votes
3 answers
131 views

#include <stdio.h> #include <stdlib.h> #define MAX_SIZE 100 // Maximum size of the arrays int main() { FILE *file; int array1[MAX_SIZE], array2[MAX_SIZE]; int i = 0, j = 0; ...
user1237538's user avatar
-1 votes
2 answers
1k views

How do I display \n as new line in text file or markdown file? I am on OSX using vscode from what I read in this StackOverflow question I understand that \n should just display as new line in text ...
echo's user avatar
  • 823
0 votes
1 answer
49 views

How come this code doesn't print a new line after the first string? 1 section .data 2 queryUserNumber db 'Pick a number between 1 and 100:' 3 queryUserNumberLength equ $ - ...
user29613085's user avatar
0 votes
1 answer
66 views

I discovered today, to my horror, that Postgres accepts newline characters inside single- and double-quoted string literals: postgres=# select 'a postgres'# b'; ┌──────────┐ │ ?column? │ ├──────────┤ │...
Andy's user avatar
  • 8,891
2 votes
2 answers
108 views

Using the documentation Everything you wanted to know about PSCustomObject $myObject = [PSCustomObject]@{ Name = 'Kevin' Language = 'PowerShell' State = 'Texas' } $myObject Above ...
dcaz's user avatar
  • 919
1 vote
1 answer
200 views

I'm rendering some YAML code with Jinja2 and am having trouble figuring out where this newline is coming from when I call a macro. Here is my YAML code: names: - Bob - Jason - James Here is my ...
sshaun_10's user avatar
0 votes
1 answer
95 views

I have a string of characters (an CSV file) that contains \r\n (or chr(13)||chr(10) in PLSQL) embedded in the data. I need to ingore these embedded Carriage Return Line Feeds so I can find the actual ...
Day's user avatar
  • 11
4 votes
3 answers
3k views

I want to print dynamic multiline text in whatsapp messages. The messages are sent via Facebook Graph API. I have used the \\n character to insert a new line. See request below. Request: POST https://...
Somanna's user avatar
  • 346
-4 votes
1 answer
81 views

I have rows in a spreadsheet that display as such They all have invisible new lines that are only visible when editing the cell. I can't figure out how to match them. \n didn't match. \n only ...
blahahaaahahaa's user avatar
0 votes
1 answer
46 views

I feel like I have a very dumb question: I create a text with the following command: text = document.createElementNS("http://www.w3.org/2000/svg", "text") text.textContent = "...
marco's user avatar
  • 312
-2 votes
1 answer
112 views

From my browser, I send the following payload as a string, <Form> <Field Sql="select top(1) Row FROM Table"> </Field> </Form> Notice how the value of Sql has ...
tRuEsAtM's user avatar
  • 3,751
2 votes
1 answer
76 views

Let us say we need to verify the following method. /** * Prints {@code hello, world}, to the {@link System#out}, followed by a system dependent line separator. * * @param args ...
Jin Kwon's user avatar
  • 22.4k
0 votes
1 answer
120 views

I had launched my programm, but it gave me a traceback that says: "line 9: is not terminated with newline". I don't see a mistake. Can someone explain it to me? init: #Название мода ...
MrNeon777's user avatar
3 votes
1 answer
288 views

If we don't end a source file with a new line character but just a } after main(), then the clang compiler (in strict mode -std=c17 -pedantic-errors) infamously complains: error: no newline at end of ...
Lundin's user avatar
  • 220k
0 votes
1 answer
123 views

I have several tab-delimited text files obtained from the FFIEC site (https://cdr.ffiec.gov/public/PWS/DownloadBulkData.aspx) <Call Reports - Single Period, Schedule RIE> that have LF (line feed)...
HBreshears's user avatar
0 votes
0 answers
296 views

I'm writing a text editor as an exercise and I'm using a gap buffer as the data structure for holding text. For a cursor, I'm just storing an index into the buffer. Here is what I'm working with: ...
SPIGS's user avatar
  • 21
1 vote
3 answers
290 views

I have recently (2-3 days ago) started to use Powershell. I have a C++ application that uses argparse to process some command line arguments. If something is not as expected, my code exits with the ...
rbaleksandar's user avatar
  • 9,862
1 vote
0 answers
52 views

How to stop commas, dots, brackets, etc. from going to new line? They need to stay on the same line with the content that is immediately before them. The svg is inserted with jQuery after the document ...
KristapsF's user avatar
0 votes
2 answers
280 views

Newline is getting interpreted as Ð (0xd0) instead of (0x0a) and I genuinely don't have any idea on how to fix this. I don't know where to begin either. When trying to use this code, it reads 0x0a as ...
soda's user avatar
  • 27
0 votes
0 answers
396 views

I am using docker/build-push-action@v5 and need to pass build-contexts from variable. Its type is List of strings: https://github.com/docker/build-push-action?tab=readme-ov-file#inputs If I specify ...
Andrius's user avatar
  • 21.5k
0 votes
3 answers
100 views

From this other SO post, learned that SET n=^&echo( echo First line%n%%n%Second line prints First line Second line How do I define nn to print 2 new lines? The following didn't work SET n=^&...
joseville's user avatar
  • 1,023
2 votes
1 answer
147 views

Say, I have a branch with several commits in it. In versions A and B, I have a file with mixed line endings (mostly LF, but some CRLF), and made various other changes to it. In version C, I made ...
Some Guy's user avatar
  • 598
-1 votes
2 answers
218 views

In apps script, how to prevent pasting text in a cell (keyboard shortcuts) with carriage returns from overwriting the values ​​below? I tried a onedit(e) function, but we cannot intercept keyboard ...
ericire's user avatar
  • 427
0 votes
1 answer
112 views

Why, if you write a string containing "\r\n" to a file opened in binary mode, and then read that string from the same file, but opened in text mode, then the string will contain '\n' ...
Pavel's user avatar
  • 354
0 votes
1 answer
680 views

I have a repository which I use between Windows and Linux. Currently some files, for example the file myfolder/myfile.txt is stored with CRLF (DOS) line endings and checked out with CRLF linedendigs. ...
halloleo's user avatar
  • 10.9k
3 votes
2 answers
94 views

I want to convert all newlines in my input string to windows newlines (\r\n). So I want to apply the following mapping: \r\n -> \r\n \r -> \r\n \n -> \r\n How should this be done?
ItIsJustMe's user avatar
0 votes
1 answer
579 views

I am using Python to automate interactions with a web application. My goal is to send newline characters into an input field to separate domain names, but all attempts have failed to properly input ...
divinem's user avatar
  • 33
0 votes
2 answers
652 views

I'm working on translating an old game. I have the strings displayed/organized like this This is a sentence that you really need to read.<End> This is also a sentence that you need to read.<...
Arlen Pavka's user avatar
-1 votes
2 answers
153 views

Why does echo interpret "\n" as new line character in interactive shells only and not when executing a shell script also? Running in an interactive bash shell: $ echo "hello\nworld"...
Semnodime's user avatar
  • 2,035
0 votes
1 answer
86 views

I am pretty new to Python, and what I'm trying to achieve is to add variables to the payload below in Python; it's meant for Zeptomail API, and I'm trying to customize and add user-specific data to ...
Raymond's user avatar
  • 13
-1 votes
1 answer
216 views

In Java, when we try to print a Hardcoded String like, "abc\nabc", we observe a line change after the first abc but when we take same input via sc.next() or sc.nextLine() it prints out '\n' ...
Digvijay Singh's user avatar
2 votes
1 answer
47 views

Why does PHP output \n here instead of actually making a newline? I'm viewing it in the terminal and saving into a text file. It displays wrongly: Lopende tekst...\nVolgende zin. It should result in: ...
Petoetje59's user avatar
1 vote
2 answers
899 views

I'm using Phoenix Code — the editor based on Brackets — as a text editor, but this is a more general issue with search and replace and new lines in regular expressions. I will often have several ...
Andrew's user avatar
  • 11
0 votes
0 answers
39 views

This program is not \n terminating and keep taking input until the size of array is specified in condition is not reached.This program should terminate when \n is encounterd. #include<iostream> ...
Ehsan Ullah's user avatar

1
2 3 4 5
103