The Inbox: MonticelloSqueak-tfel.1.mcz

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

The Inbox: MonticelloSqueak-tfel.1.mcz

commits-2
A new version of MonticelloSqueak was added to project The Inbox:
http://source.squeak.org/inbox/MonticelloSqueak-tfel.1.mcz

==================== Summary ====================

Name: MonticelloSqueak-tfel.1
Author: tfel
Time: 12 June 2010, 3:11:21.978 pm
UUID: b20624b1-6525-443e-9487-51dcdf6ec633
Ancestors:

This package includes the MCTrunkCommitHelper class which I propose to simplify contributing to the inbox for new Squeakers (or old Squeakers new to the trunk development model).
It depends on Monticello-tfel.395

==================== Snapshot ====================

SystemOrganization addCategory: #MonticelloSqueak!

Object subclass: #MCTrunkCommitHelper
        instanceVariableNames: 'workingCopy'
        classVariableNames: ''
        poolDictionaries: ''
        category: 'MonticelloSqueak'!

!MCTrunkCommitHelper commentStamp: 'tfel 6/12/2010 14:43' prior: 0!
A MCTrunkCommitHelper is a simple wizard-ish class that leads a Squeaker new to the trunk development model of Squeak through the first steps of contributing changes to the inbox.
It adds a new entry to the Monticello Browser's context menu for that.!

----- Method: MCTrunkCommitHelper classSide>>diffExplanation (in category 'accessing-text') -----
diffExplanation

        ^ 'You will now be presented a diff of your changes against current trunk.
        - If you have updated, please make sure your changes still work.
        - Make sure you don''t submit more changes than you intent to
          (Use method versions to remove changes you do not want to submit) '!

----- Method: MCTrunkCommitHelper classSide>>inboxSubmitQuestion (in category 'accessing-text') -----
inboxSubmitQuestion

        ^ 'After reviewing the changes:
        Explain your changes in the commit message. If the changes are
        more complex and require a longer explanation, consider writing an
        email to the squeak-dev mailing list
       
        Do you want to commit now?'!

----- Method: MCTrunkCommitHelper classSide>>inboxUrl (in category 'accessing-urls') -----
inboxUrl

        ^ 'http://source.squeak.org/inbox'!

----- Method: MCTrunkCommitHelper classSide>>initialize (in category 'class initialization') -----
initialize

        super initialize.
        MCWorkingCopyBrowser
                addMenuSpec: (MCMenuSpec new
                        entry: 'submit to squeak inbox';
                        target: self new;
                        selector: #submit:;
                        yourself).!

----- Method: MCTrunkCommitHelper classSide>>trunkExplanation (in category 'accessing-text') -----
trunkExplanation

        ^ 'The Squeak development happens in the trunk.
        To submit patches, you have to update to the latest Squeak development version.
        This version, while not released, is used by many Developers around the world.
        However, if you have critical code running in this very image, you might want to save it
        as a new version just in case.
       
        If you want to contribute to Squeak, you might want to sign up to the squeak-dev mailinglist
        as well. For further explanation of the trunk model, see
        http://squeakboard.wordpress.com/2009/07/02/a-new-community-development-model/
       
        Do you want to update?'!

----- Method: MCTrunkCommitHelper classSide>>trunkUrl (in category 'accessing-urls') -----
trunkUrl

        ^ 'http://source.squeak.org/trunk'!

----- Method: MCTrunkCommitHelper>>checkDiff (in category 'actions') -----
checkDiff

        | patch |
        self inform: self class diffExplanation.
        patch := workingCopy changesRelativeToRepository: self trunk.
        ^ (patch isNil or: [patch isEmpty])
                ifTrue: [self inform: 'No changes against trunk. Aborting submission'. false]
                ifFalse: [(MCPatchBrowser forPatch: patch)
                                        label: 'Patch Browser: ', workingCopy description;
                                        showModally.
                                true].!

----- Method: MCTrunkCommitHelper>>goToTrunk (in category 'actions') -----
goToTrunk

        (MCMcmUpdater defaultUpdateURL = self class trunkUrl
                or: [(UserDialogBoxMorph confirm: self class trunkExplanation)])
                ifTrue: [
                        MCMcmUpdater defaultUpdateURL: self class trunkUrl.
                        self updateToTrunk.
                        ^ true].
        ^ false!

----- Method: MCTrunkCommitHelper>>inbox (in category 'repositories') -----
inbox

        ^ MCHttpRepository allInstances
                detect: [:r | r locationWithTrailingSlash = (self class inboxUrl, '/')]
                ifNone: [MCHttpRepository location: self class inboxUrl user: '' password: ''].!

----- Method: MCTrunkCommitHelper>>save: (in category 'actions') -----
save: aMCWorkingCopyBrowser

        aMCWorkingCopyBrowser
                workingCopy: workingCopy;
                repository: self inbox;
                saveVersion.!

----- Method: MCTrunkCommitHelper>>submit: (in category 'actions') -----
submit: aMCWorkingCopyBrowser

        workingCopy := aMCWorkingCopyBrowser workingCopies
                at: aMCWorkingCopyBrowser workingCopySelection.
        self goToTrunk
                ifTrue: [
                        self checkDiff ifTrue: [
                                (UserDialogBoxMorph confirm: self class inboxSubmitQuestion)
                                        ifTrue: [self save: aMCWorkingCopyBrowser]]].!

----- Method: MCTrunkCommitHelper>>trunk (in category 'repositories') -----
trunk

        ^ MCHttpRepository allInstances
                detect: [:r | r locationWithTrailingSlash = (self class trunkUrl, '/')]
                ifNone: [MCHttpRepository location: self class inboxUrl user: '' password: ''].!

----- Method: MCTrunkCommitHelper>>updateToTrunk (in category 'actions') -----
updateToTrunk

        Utilities updateFromServer.!


Reply | Threaded
Open this post in threaded view
|

Re: The Inbox: MonticelloSqueak-tfel.1.mcz

Tim Felgentreff
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi
Not meaning to be a PITA just really care about this...

I talked with a couple of people studying with me who also use Squeak and some of them seemed to be unsure how contributing works. They are on the ML and know that there are such things as the trunk and the inbox, but they feel it would take some time for them to start contributing code from their 4.1 image and so they haven't come around to doing that yet. I want to show them that committing is easy and they can do it without having to spend time on finding out how.

I know, a committed developer who is willing to spend time on contributions is a good thing, but I feel that the Squeak community is missing out on opportunities if people are "put off" by a vague feeling that starting to commit code isn't easy.
That's why I proposed the solution of a right-click "wizard" to help people quickly get their changes into the inbox. It's just an idea, but I would like to hear what you think.

Regards
Tim
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (Darwin)

iEYEARECAAYFAkwVgygACgkQLbWJItnd6CwTewCgoDhNQF3fQkPm2myjcbilyuJs
jCYAoKZoxHO3GcC0rmRIlmLURrOWvtg5
=YgsJ
-----END PGP SIGNATURE-----

Reply | Threaded
Open this post in threaded view
|

Re: The Inbox: MonticelloSqueak-tfel.1.mcz

Michael Haupt-3
Tim,

I really like this proposal, and the idea of guiding "new" people
through parts of the system using wizards. Still, the solution seems
(!) to be rather stand-alone: how about integrating it with the help
system that is available anyway?

Read: the help material available could be extended by a section
(book) on people new to Squeak and the community process. On top of
that, some kind of context-sensitive help might pop up at points like
the one your proposal attaches to, and lead to the corresponding
documentation open in the help browser if the user accepts.

Best,

Michael

Reply | Threaded
Open this post in threaded view
|

Re: The Inbox: MonticelloSqueak-tfel.1.mcz

Bert Freudenberg
In reply to this post by Tim Felgentreff
On 14.06.2010, at 03:17, Tim Felgentreff wrote:

> I talked with a couple of people studying with me who also use Squeak and some of them seemed to be unsure how contributing works. They are on the ML and know that there are such things as the trunk and the inbox, but they feel it would take some time for them to start contributing code from their 4.1 image and so they haven't come around to doing that yet. I want to show them that committing is easy and they can do it without having to spend time on finding out how.

Did you show them the screencast I made a couple months back?

        http://vimeo.com/7783848

The only difference would be to choose the "inbox" repository when committing (not when comparing).

- Bert -


Reply | Threaded
Open this post in threaded view
|

Re: The Inbox: MonticelloSqueak-tfel.1.mcz

Tim Felgentreff
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

- -----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi Bert

No, I didn't know about that screencast.
However, first, this doesn't work directly with a 4.1 release image (you have to change the update url to trunk) and more importantly I'm thinking about people here who won't take the time to watch even a 5min screencast - leave alone try to figure out how to do what you are showing in a 4.1 release image.
Many people just don't want to switch contexts to find out about such a thing - I believe the Squeak environment especially has strong inertia keeping people in the image.

Regards,
Tim

On Jun 14, 2010, at 10:52 AM, Bert Freudenberg wrote:

> On 14.06.2010, at 03:17, Tim Felgentreff wrote:
>
>> I talked with a couple of people studying with me who also use Squeak and some of them seemed to be unsure how contributing works. They are on the ML and know that there are such things as the trunk and the inbox, but they feel it would take some time for them to start contributing code from their 4.1 image and so they haven't come around to doing that yet. I want to show them that committing is easy and they can do it without having to spend time on finding out how.
>
> Did you show them the screencast I made a couple months back?
>
> http://vimeo.com/7783848
>
> The only difference would be to choose the "inbox" repository when committing (not when comparing).
>
> - Bert -
>
>

- -----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (Darwin)

iEYEARECAAYFAkwV9EkACgkQLbWJItnd6CyqgACgx/nyh+pz7dPy9PwSue1+il89
FJAAnRYZZI5KOpkJKECtdTRiM70EH3rg
=byvL
- -----END PGP SIGNATURE-----
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (Darwin)

iEYEARECAAYFAkwV9/sACgkQLbWJItnd6CzYFACcCNqdlRoBo3TgD+FUJOycluLM
DToAniuPkH3HBAWNxX1z9He5AgOmZ3nK
=XWtb
-----END PGP SIGNATURE-----