Differences between unique_ptr and shared_ptr
> [pimpl: shared_ptr or unique_ptr](https://stackoverflow.com/questions/5576922/pimpl-shared-ptr-or-unique-ptr) [smart pointers (boost) explained](https://stackoverflow.com/questions/569775/smart...
- Modified
- 23 May at 12:2
How can you run a command in bash over and over until success?
I have a script and want to ask the user for some information, but the script cannot continue until the user fills in this information. The following is my attempt at putting a command into a loop to ...
- Modified
- 11 Dec at 07:15
How do I specify different Layouts in the ASP.NET MVC 3 razor ViewStart file?
I would like to have 2 separate Layouts in my application. Let's say one is for the Public section of the website and the other is for the Member side. For simplicity, let's say all the logic for each...
- Modified
- 27 Jul at 14:42
Cannot run Eclipse; JVM terminated. Exit code=13
![enter image description here](https://i.stack.imgur.com/qi9fH.jpg) I just append -vm C:\Program Files\Java\jre6\bin\javaw.exe in eclipse.ini then I try to start eclipse again and got this error. ...
What is the difference between URI, URL and URN?
What's the difference between an URI, URL and URN? I have read a lot of sites (even Wikipedia) but I don't understand it. URI: [http://www.foo.com/bar.html](http://www.foo.com/bar.html) URL: [http://...
Getting file names without extensions
When getting file names in a certain folder: ``` DirectoryInfo di = new DirectoryInfo(currentDirName); FileInfo[] smFiles = di.GetFiles("*.txt"); foreach (FileInfo fi in smFiles) { builder.Append...
How to replace captured groups only?
I have HTML code before and after the string: ``` name="some_text_0_some_text" ``` I would like to replace the `0` with something like : `!NEW_ID!` So I made a simple regex : ``` .*name="\w+(\d+)\w+...
- Modified
- 7 Nov at 13:3
Why does make think the target is up to date?
This is my Makefile: ``` REBAR=./rebar REBAR_COMPILE=$(REBAR) get-deps compile all: compile compile: $(REBAR_COMPILE) test: $(REBAR_COMPILE) skip_deps=true eunit clean: -rm -rf deps eb...
- Modified
- 22 Dec at 02:42
Rails Root directory path?
How do I get my Rails app's root directory path?
- Modified
- 19 Sep at 08:19
UILabel text margin
I'm looking to set the left inset/margin of a `UILabel` and can't find a method to do so. The label has a background set so just changing its origin won't do the trick. It would be ideal to inset the ...
- Modified
- 22 Dec at 11:54
Using Linq to get the last N elements of a collection?
Given a collection, is there a way to get the last N elements of that collection? If there isn't a method in the framework, what would be the best way to write an extension method to do this?
Java how to replace 2 or more spaces with single space in string and delete leading and trailing spaces
Looking for quick, simple way in Java to change this string ``` " hello there " ``` to something that looks like this ``` "hello there" ``` where I replace all those multiple spaces with ...
How to bold one output text in Bash?
I'm writing a Bash script that prints some text to the screen: ``` echo "Some Text" ``` Can I format the text? I would like to make it bold.
- Modified
- 27 Dec at 15:22
How do I convert a column of text URLs into active hyperlinks in Excel?
I have a column in excel, wherein I have all the website url values. My question is I want to turn the url values to active links. There are about 200 entries in that column with different urls in all...
- Modified
- 14 Dec at 10:0
Delete specific line number(s) from a text file using sed?
I want to delete one or more specific line numbers from a file. How would I do this using sed?
- Modified
- 21 Jan at 20:8
What does "exited with code 9009" mean during this build?
What does this error message mean? What could I do to correct this issue? > AssemblyInfo.cs exited with code 9009 --- The problem is probably happening as part of a post-build step in a .NET sol...
- Modified
- 15 Mar at 15:4
In jQuery, how do I select an element by its name attribute?
I have 3 radio buttons in my web page, like below: ``` <label for="theme-grey"> <input type="radio" id="theme-grey" name="theme" value="grey" />Grey</label> <label for="theme-pink"> <input type="...
- Modified
- 19 Jun at 16:17
How to use conditional statement within child attribute of a Flutter Widget (Center Widget)
So far whenever I needed to use a conditional statement within a Widget I have done the following (Using Center and Containers as simplified dummy examples): ``` new Center( child: condition == tr...
- Modified
- 23 Apr at 03:47
Unable to import svg files in typescript
In `typescript(*.tsx)` files I cannot import svg file with this statement: ``` import logo from './logo.svg'; ``` Transpiler says:`[ts] cannot find module './logo.svg'.` My svg file is just `<svg>....
- Modified
- 23 Jun at 08:54
Having services in React application
I'm coming from the angular world where I could extract logic to a service/factory and consume them in my controllers. I'm trying to understand how can I achieve the same in a React application. Let...
- Modified
- 7 Mar at 22:53
How to get the Development/Staging/production Hosting Environment in ConfigureServices
How do I get the Development/Staging/production Hosting Environment in the `ConfigureServices` method in Startup? ``` public void ConfigureServices(IServiceCollection services) { // Which environ...
- Modified
- 27 Feb at 10:27
Table 'performance_schema.session_variables' doesn't exist
After upgrading MySQL to 5.7.8-rc and loging to server I got error: ``` Table 'performance_schema.session_variables' doesn't exist ``` I can't find any solution for this. Can you help ?
Visual Studio displaying errors even if projects build
I have a problem with Visual Studio on a C# solution. It displays totally random errors, but the projects build. Right now, I have 33 files with errors, and I can see red squiggly lines in all of them...
- Modified
- 26 Aug at 03:26
How to show Git log history (i.e., all the related commits) for a sub directory of a Git repository
Let’s say that I have a Git repository that looks like this: ``` foo/ .git/ A/ ... big tree here B/ ... big tree here ``` Is there a way to ask `git log` to show only the log messages for...
- Modified
- 22 Jan at 20:16
TypeScript, Looping through a dictionary
In my code, I have a couple of dictionaries (as suggested [here](https://web.archive.org/web/20140901130959/https://typescript.codeplex.com/discussions/398359)) which is String indexed. Due to this be...
- Modified
- 28 Apr at 09:14