Questions

How to pass command line arguments to a shell alias?

How do I pass the command line arguments to an alias? Here is a sample: But in this case the $xx is getting translated at the alias creating time and not at runtime. I have, however, created a wor...

16 Oct at 03:50

How to convert JSON to XML or XML to JSON?

I started to use Json.NET to convert a string in JSON format to object or viceversa. I am not sure in the Json.NET framework, is it possible to convert a string in JSON to XML format and viceversa?

3 Nov at 19:14

Remove a cookie

When I want to remove a Cookie I try ``` unset($_COOKIE['hello']); ``` I see in my cookie browser from firefox that the cookie still exists. How can I really remove the cookie?

26 Mar at 15:5

How to delete a workspace in Eclipse?

How to delete a workspace in Eclipse?

25 Oct at 22:5

Type safety: Unchecked cast

In my spring application context file, I have something like: ``` <util:map id="someMap" map-class="java.util.HashMap" key-type="java.lang.String" value-type="java.lang.String"> <entry key="some_k...

27 Jul at 05:34

strdup() - what does it do in C?

What is the purpose of the `strdup()` function in C?

2 Jul at 16:20

What's the strangest corner case you've seen in C# or .NET?

I collect a few corner cases and [brain teasers](http://www.yoda.arachsys.com/csharp/teasers.html) and would always like to hear more. The page only really covers C# language bits and bobs, but I also...

4 Feb at 22:53

How to resolve: 'keyWindow' was deprecated in iOS 13.0

I'm using Core Data with Cloud Kit, and have therefore to check the iCloud user status during application startup. In case of problems I want to issue a dialog to the user, and I do it using `UIApplic...

9 Oct at 04:42

React : difference between <Route exact path="/" /> and <Route path="/" />

Can someone explain the difference between ``` <Route exact path="/" component={Home} /> ``` and ``` <Route path="/" component={Home} /> ``` I don't know the meaning of `exact`.

standard_init_linux.go:178: exec user process caused "exec format error"

docker started throwing this error: > standard_init_linux.go:178: exec user process caused "exec format error" whenever I run a specific docker container with CMD or ENTRYPOINT, with no regard to an...

27 Feb at 20:8

How to query all the GraphQL type fields without writing a long query?

Assume you have a GraphQL type and it includes many fields. How to query all the fields without writing down a long query that includes the names of all the fields? For example, If I have these field...

7 Nov at 16:24

Simple way to measure cell execution time in ipython notebook

I would like to get the time spent on the cell execution in addition to the original output from cell. To this end, I tried `%%timeit -r1 -n1` but it doesn't expose the variable defined within cell. `...

How to install and use "make" in Windows?

I'm following the instructions of someone whose repository I cloned to my machine. I want to use the `make` command as part of setting up the code environment, but I'm using Windows. I searched online...

5 Mar at 23:9

Git - What is the difference between push.default "matching" and "simple"

I have been using git for a while now, but I have never had to set up a new remote repo myself and I have been curious on doing so. I have been reading tutorials and I am confused on how to get "git p...

27 Jul at 13:59

Moment JS - check if a date is today or in the future

I am trying to use `momentjs` to check if a given date is today or in the future. This is what I have so far: ``` <script type="text/javascript" src="http://momentjs.com/downloads/moment.min.js"></s...

22 Jan at 13:31

Installing Java on OS X 10.9 (Mavericks)

I have installed the [JDK](http://en.wikipedia.org/wiki/Java_Development_Kit) on [Mac OS X v10.8](http://en.wikipedia.org/wiki/OS_X_Mountain_Lion) (Mountain Lion). When I upgraded it to [Mac OS X v10....

6 Aug at 18:57

How to run crontab job every week on Sunday

I'm trying to figure out how to run a crontab job every week on Sunday. I think the following should work, but I'm not sure if I understand correctly. Is the following correct? ``` 5 8 * * 6 ```

29 Oct at 17:39

"tmux set -g mouse-mode on" not scrolling

To allow scrolling a tmux pane with a mouse, I put the following in my `~/.tmux.conf` file: ``` set -g mouse-mode on ``` However, nothing changes. When I scroll, it still scrolls outside of tmux. Why...

17 Aug at 08:37

The Web Application Project [...] is configured to use IIS. The Web server [...] could not be found.

I have a web project in my solution file that is "unavailable" when I open the solution. When I right-click on the web project and reload the project, I get the following error: `The Web Application ...

25 Sep at 13:43

How to make my custom type to work with "range-based for loops"?

Like many people these days I have been trying the different features that C++11 brings. One of my favorites is the "range-based for loops". I understand that: ``` for(Type& v : a) { ... } ``` Is ...

3 Mar at 08:30

Is the order of elements in a JSON list preserved?

I've noticed the order of elements in a JSON object not being the original order. What about the elements of JSON lists? Is their order maintained?

24 Jan at 13:23

What is "git remote add ..." and "git push origin master"?

Quite often, Git and [Ruby on Rails](https://en.wikipedia.org/wiki/Ruby_on_Rails) looks like magic... such as in the [first chapter of Ruby on Rails 3 Tutorial book](http://ruby.railstutorial.org/chap...

13 Jun at 16:40

How can I format a number into a string with leading zeros?

I have a number that I need to convert to a string. First I used this: ``` Key = i.ToString(); ``` But I realize it's being sorted in a strange order and so I need to pad it with zeros. How could I...

27 Mar at 09:51

What is a PDB file?

What is a PDB file and how can I exclude it from the release folder when I rebuild my solution?

10 Oct at 08:33

Measure execution time for a Java method

How do I calculate the time taken for the execution of a method in Java?

5 Jan at 19:46