New web tutorial

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

New web tutorial

stepharo
Hi guys

with Olivier Auverlot we did several attempts (over the year) and we are
happy to release a first draft of a web tutorial
around Pharo. We ask the user to build a simple blog engine.

It goes over
     - Mongo
     - Seaside
     - Magritte

https://ci.inria.fr/pharo-contribution/job/TinyBlogTutorial/5/artifact/book-result/output.pdf

Soon Rest/Deployment/Garage?/NeoJSON/XML

If you want to participate (translate it to english) or improve it you
are welcome.

We hope that it will serve as a basis to a lot of Seaside applications.

This tutorial will be used in the lecture I'm giving next weeks in Togo
and will be edited as a lulu book.

Stef and Olivier.




Reply | Threaded
Open this post in threaded view
|

Re: [Pharo-users] New web tutorial

NorbertHartl
Looks good but I don't understand it :)

Norbert

> Am 13.12.2015 um 22:13 schrieb stepharo <[hidden email]>:
>
> Hi guys
>
> with Olivier Auverlot we did several attempts (over the year) and we are happy to release a first draft of a web tutorial
> around Pharo. We ask the user to build a simple blog engine.
>
> It goes over
>    - Mongo
>    - Seaside
>    - Magritte
>
> https://ci.inria.fr/pharo-contribution/job/TinyBlogTutorial/5/artifact/book-result/output.pdf
>
> Soon Rest/Deployment/Garage?/NeoJSON/XML
>
> If you want to participate (translate it to english) or improve it you are welcome.
>
> We hope that it will serve as a basis to a lot of Seaside applications.
>
> This tutorial will be used in the lecture I'm giving next weeks in Togo and will be edited as a lulu book.
>
> Stef and Olivier.
>
>
>
>

Reply | Threaded
Open this post in threaded view
|

Re: New web tutorial

Stephan Eggermont-3
In reply to this post by stepharo
Instead of the really unsafe password: thing, perhaps use

hashPassword: aString
        ^GRPlatform current secureHashFor: aString

password: anObject
        passwordHash := self hashPassword: anObject

verifyPassword: aString
        ^(self hashPassword: aString) = self passwordHash.

passwordHash
        passwordHash ifNil: [ ^'' ].
        ^ passwordHash


Reply | Threaded
Open this post in threaded view
|

Re: New web tutorial

Sven Van Caekenberghe-2

> On 15 Dec 2015, at 10:19, Stephan Eggermont <[hidden email]> wrote:
>
> Instead of the really unsafe password: thing, perhaps use
>
> hashPassword: aString
> ^GRPlatform current secureHashFor: aString
>
> password: anObject
> passwordHash := self hashPassword: anObject
>
> verifyPassword: aString
> ^(self hashPassword: aString) = self passwordHash.
>
> passwordHash
> passwordHash ifNil: [ ^'' ].
> ^ passwordHash

That last method is not needed, since 'any string' = nil is false, right ?


Reply | Threaded
Open this post in threaded view
|

Re: New web tutorial

Stephan Eggermont-3
On 15-12-15 10:23, Sven Van Caekenberghe wrote:
>> passwordHash
>> passwordHash ifNil: [ ^'' ].
>> ^ passwordHash
>
> That last method is not needed, since 'any string' = nil is false, right ?

Yep.

Stephan


Reply | Threaded
Open this post in threaded view
|

Re: New web tutorial

Sven Van Caekenberghe-2

> On 15 Dec 2015, at 10:34, Stephan Eggermont <[hidden email]> wrote:
>
> On 15-12-15 10:23, Sven Van Caekenberghe wrote:
>>> passwordHash
>>> passwordHash ifNil: [ ^'' ].
>>> ^ passwordHash
>>
>> That last method is not needed, since 'any string' = nil is false, right ?
>
> Yep.

Nu we toch Nederlands mogen praten, het lijkt me best om voorbeeld code zo minimaal mogelijk te houden. De paswoord hashing is wel een goed idee.

;-)


Reply | Threaded
Open this post in threaded view
|

Re: New web tutorial

Stephan Eggermont-3
On 15-12-15 10:39, Sven Van Caekenberghe wrote:
> Nu we toch Nederlands mogen praten, het lijkt me best om voorbeeld code zo minimaal mogelijk te houden. De paswoord hashing is wel een goed idee.

Mijn Frans is best aardig, maar dit (pagina 63) begrijp ik niet helemaal:

"If you run the test, it will fail because the system returns instances
of posts instead of 2. Why this is happening? We never told the system
that posts are objects that should be saved in the database."



Reply | Threaded
Open this post in threaded view
|

Re: New web tutorial

Skip Lentz-2
In reply to this post by Sven Van Caekenberghe-2

> On Dec 15, 2015, at 10:39 AM, Sven Van Caekenberghe <[hidden email]> wrote:
>
>
>> On 15 Dec 2015, at 10:34, Stephan Eggermont <[hidden email]> wrote:
>>
>> On 15-12-15 10:23, Sven Van Caekenberghe wrote:
>>>> passwordHash
>>>> passwordHash ifNil: [ ^'' ].
>>>> ^ passwordHash
>>>
>>> That last method is not needed, since 'any string' = nil is false, right ?
>>
>> Yep.
>
> Nu we toch Nederlands mogen praten, het lijkt me best om voorbeeld code zo minimaal mogelijk te houden. De paswoord hashing is wel een goed idee.

Yay Nederlanders :D
Reply | Threaded
Open this post in threaded view
|

Re: New web tutorial

philippeback
En franstaligers die nederlands kunnen begrijpen.

Schrijven is een andere verhaal :-)

Phil

On Tue, Dec 15, 2015 at 12:11 PM, Skip Lentz <[hidden email]> wrote:

> On Dec 15, 2015, at 10:39 AM, Sven Van Caekenberghe <[hidden email]> wrote:
>
>
>> On 15 Dec 2015, at 10:34, Stephan Eggermont <[hidden email]> wrote:
>>
>> On 15-12-15 10:23, Sven Van Caekenberghe wrote:
>>>> passwordHash
>>>>    passwordHash ifNil: [ ^'' ].
>>>>    ^ passwordHash
>>>
>>> That last method is not needed, since 'any string' = nil is false, right ?
>>
>> Yep.
>
> Nu we toch Nederlands mogen praten, het lijkt me best om voorbeeld code zo minimaal mogelijk te houden. De paswoord hashing is wel een goed idee.

Yay Nederlanders :D

Reply | Threaded
Open this post in threaded view
|

Re: New web tutorial

Sven Van Caekenberghe-2
In reply to this post by Stephan Eggermont-3

> On 15 Dec 2015, at 12:04, Stephan Eggermont <[hidden email]> wrote:
>
> On 15-12-15 10:39, Sven Van Caekenberghe wrote:
>> Nu we toch Nederlands mogen praten, het lijkt me best om voorbeeld code zo minimaal mogelijk te houden. De paswoord hashing is wel een goed idee.
>
> Mijn Frans is best aardig, maar dit (pagina 63) begrijp ik niet helemaal:
>
> "If you run the test, it will fail because the system returns instances of posts instead of 2. Why this is happening? We never told the system that posts are objects that should be saved in the database."

Après 63 pages, l'Anglais revient pour un paragraphe ... haha


Reply | Threaded
Open this post in threaded view
|

Re: New web tutorial

stepharo
I was probably in automatic text writing mode :)
We will try to translate the tutorial but first we should finish it.

Stef

Le 15/12/15 12:46, Sven Van Caekenberghe a écrit :

>> On 15 Dec 2015, at 12:04, Stephan Eggermont <[hidden email]> wrote:
>>
>> On 15-12-15 10:39, Sven Van Caekenberghe wrote:
>>> Nu we toch Nederlands mogen praten, het lijkt me best om voorbeeld code zo minimaal mogelijk te houden. De paswoord hashing is wel een goed idee.
>> Mijn Frans is best aardig, maar dit (pagina 63) begrijp ik niet helemaal:
>>
>> "If you run the test, it will fail because the system returns instances of posts instead of 2. Why this is happening? We never told the system that posts are objects that should be saved in the database."
> Après 63 pages, l'Anglais revient pour un paragraphe ... haha
>
>
>