« first day (15 days earlier)      last day (3224 days later) » 
07:00 - 20:0020:00 - 23:00

8:00 PM
still dismayed that this guy is arguing
oh kruger-dunning.
 
<[^>]>
 

Sandbox

Where you can play with regular chat features (except flagging...
 
@Chacha102 I think you want <[^>]*>
wth
that's fantastic.
 
@balpha You've outdone yourself...
 
Hey guys quick question, I created a brand new Visual Studio solution and then used Mercurial to commit that. I tinkered with the application a bit and nowI'd like to completely undo my changes, meaning revert to that initial commit,delting the changes from disc. What HG command doI need to run?
 
8:05 PM
the new stuff isn't commited yet?
hg revert --all
alternative: hg up -r0 --clean
 
Yes, the new stuffhasn't been commited
what does the '-all' option do?\
 
hg revert usually takes a filename
 
hg help revert
 
--all means anything you've done
 
So that would revert me to the initial commit correct?
 
8:10 PM
it will revert you to the parent of your working folder
if you committed, changed something, committed again, changed something and now wants to revert, it'll revert you back to that second commit
 
Typing in hg log, I can seemyinitla commit. Can I do something like hg revert changeset xxx?
 
well, hg revert reverts your current changes, some or all
you can also say "update to a specific changeset, and discard all my changes at the same time", that's what that hg up that balpha posted above does
 
for learning Mercurial: Since Joel is my CEO, I feel obligated to mention hginit.com, but I can really recommend hgbook.red-bean.com
 
Both are really good resources, and of course hg help XYZ gives help on all commands
so hg help revert and hg help update will tell you about all the options
@Serg What OS are you on?
 
Windows 7
 
8:13 PM
Do you have TortoiseHg installed?
 
No I do everything in the cmd.
 
Also, if you're working in Visual Studio, consider either HgSCC or VisualHG, both of which integrates TortoiseHg into Visual Studio.
 
I tried using VisualHG but clicking the buttons never did anything. Not even invoke a dialog.
 
If you didn't have TortoiseHg installed, they won't do anything, that's correct
 
But now that you mention it, it's probably because I only installed VisualHG and NOT TortoiseHg.
I'll definitely take a look at them.
 
8:16 PM
I would definitely learn most typical HG commands, but I would also install TortoiseHg for the most typical ones, which makes them much easier to use
 
Now I found this: hg revert [-r Revision] so how can I find the revision variable? Do they mean Changeset? Because I can see the changeset value by using hg log.
 
use either the changeset hash or the changeset number
the hash is usually safer
changeset:   3223:7cdfff0902a7
tag:         tip
user:        balpha
date:        Sun Oct 31 17:06:07 2010 +0100
summary:     prevent a JS exception when clicking 'see full text' on multiline message
so 7cdfff is your hash
 
Aha! Thanks, I'll try it. Why is the hash safer?
 
well, 3233 is the changeset number in this case, which is fine locally, but might be different if someone else has a clone of the repo
 
Ah...
Yeah I see your point.
"abort: no files or directories specified" when running hg revert -r <myhashhere>
 
8:21 PM
still need --all
unless you give a specific file
 
"hg revert -all -r <hashere>" still gives me that error. :\ Maybe I should just get the GUI?
 
double dash
 
--all
 
Yep :o That worked. Missed the double dashes.
OK! Seems like it's worked. Do I need to anything else to this?
 
8:23 PM
You only need the command line tools
But you should consider the ones that integrate into Windows Explorer and Visual Studio
Also, create some example repositories in your temp directory and experiment with cloning, pushing, pulling, merging, etc.
 
Viewing the folder in Windows Explorer I see that the added projects, etc. are still there. I imagine the hg commands only 'unlinked' them from the source control. How can I tell it to revert and delete anything that wasn't there at that specific commit?
 
the easiest way is actually making a fresh clone
so hg clone myproject cloneofmyproject
then delete and rename
if you really want to get rid of everything
 
Can't he just delete everything but the .hg directory, and do another revert?
 
@balpha That sounds kind of unproductive? :\ I imagine Mercurial had this process to the T; ESPECIALLY this process since that's the point of a source control system.
 
@LasseVKarlsen either way works, I find mine easier :)
 
8:29 PM
Basically here's the play by play: Created a new Windows Forms project; created a repo, commited; added some things to it just to test. Now I'd like Mercurial to wind back the clocks to what I had before adding the testing things.
 
If you have the purge extension enabled, you can just do:
hg purge
 
Using the hg revert command worked, but the files are still on my disc.
 
You reverted adding the files to the repo, it didn't delete the files
mercurial only reverts the actions that relates to its operations
 
But I never manually typed in hg add to the terminal after adding the testing stuff.
Unless it does this automatically?
 
If you didn't do that, then mercurial never knew about your files
 
8:31 PM
you might have written some notes.txt into the directory -- Mercurial won't touch that
 
in which case only doing a revert won't touch your files at all
Remember, source control is about avoiding shooting yourself in the foot
 
@Serg did you create and new files?
 
It will never remove any files it isn't explicitly tracking
 
the idea of "you have to notify the source control tool that you touched this file" is git, not mercurial
 
Hi again everyone
 
8:33 PM
Yeah, sorry, should've specified. What I meant was that it won't touch the files you haven't added to the repo
 
once you told Mercurial "BlaController.cs is important", it will always track it
 
If you add the files, then revert before you commit, it will only revert the add action
It will not delete the file
I tend to only use the visual tools for most operations
And if I come into this situation, I cheat :P
I use the commit dialog of TortoiseHg, which will list untracked files, and it will have delete operations on those
 
and it has checkboxes for which files you want to commit and which not
I find that most interesting
since I pretty often have changes for me locally that I don't want to have in production
(connection strings, special-casing for localhost, etc.)
 
Ok
After reading the things posted, I'm still lost. :P It seems that creating new classes/packages in Visual Studio doesn't alert Mercurial that they exist/track. So reverting won't delete them from disc, correct?
 
Yep, and you can also commit individual changes to files
So if you change two methods in a file, you can commit them separately
@Serg If you install one of the VS addins, they should take care of that
That is....
The addins will add the files/projects to the repo, but if you revert, you only revert the addition, the files will still be on disc
 
8:42 PM
Yeah I'll definitely look into it. Basically it's first install TortoiseHG, the VisualStudioHG, right?
 
Yes
 
Don't think it matters which order you do it in
But both are needed
 
And you have to choose visualhg as your source control provider in the VS options
 
Thanks guys, learned some cool things in the last 30 minutes. :P
 
This is actually what chat is great for. There's no SO question in here, but it's still helpful
 
user400055
8:47 PM
Does anyone have a good cure for what is best known as procrastination
 
@ExtremeCoder Doing the work.
 
user400055
?
 
user400055
Haha
 
Seriously, the best approach is just to dive in, and start doing it
 
user400055
Yeah I know, once you get into it it's okay... but it's getting into it
 
8:49 PM
Set yourself a tiny milestone.
Man working with SQLite is so wierd. Just random errors that shouldn't be happening and I have no idea how to solve.
For example:
0
Q: ArgumentException was unhandled.

SergHere's a screenshot of the error: The error itself is: The specified named connection is either not found in the configuration, not intended to be used with the EntityClient provider, or not valid. Going to the app.config file of that same project I can find: <?xml version="1.0" encoding...

Doing the exact same thing with good ol Microsoft SQL Server doesn't give me errors at all.
I'm just burnt out today; I'll work on it tomorrow but I don't know.
 
I've got work to do, but that article about procrastination really made me want to go clean up my Netflix queue.
 
9:26 PM
What is everyone up to?
 
I am
and I code
 
9:58 PM
Does anyone know what this phenomenon is called: Why two blinkings lights blink at different intervals, they eventually sync up for a split second then diverge again.
 
10:15 PM
If it's in musical waves it's called beats, I think
 
In acoustics, a beat is an interference between two sounds of slightly different frequencies, perceived as periodic variations in volume whose rate is the difference between the two frequencies. With tuning instruments that can produce sustained tones, beats can readily be recognized. Tuning two tones to a unison will present a peculiar effect: when the two tones are close in pitch but not yet identical, the difference in frequency generates the beating. The volume varies like in a tremolo as the sounds alternately interfere constructively and destructively. When the two tones gradually ...
Even
 
10:42 PM
@shin
oops @Shingara should it be "I code therefore I debug" ?
 
I code my test before my code so i limit the risk
 
that's no guarantee there is no bug
:)
 
completly
just limit the risk
 
"He who has not debugged, don't cast the first breakpoint.."
 
"Let he who codes without error cast the first downvote."
3
 
07:00 - 20:0020:00 - 23:00

« first day (15 days earlier)      last day (3224 days later) »