Porting code from other Smalltalks

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

Porting code from other Smalltalks

Sean P. DeNigris
Administrator
To port a package from Pharo 3.0 to Amber, I followed the instructions at https://github.com/amber-smalltalk/amber/wiki/Porting-code-from-other-Smalltalk-dialects

I then added "" to my index.html. However, when I tried to open Helios, I got "JavaScript exception: TypeError: undefined is not a function"

Noticing that amberc had put my packages in the amber_core namespace, I changed it to the namespace of my project, and then everything worked as expected.

So I'm assuming that porting into the same namespace as the rest of the project is best practice. If so, should we add that (i.e. using amberc -n) to those instructions?

Also, a more minor point. There are alternate instructions on porting code at https://github.com/amber-smalltalk/amber/wiki/Filing-in-code-recipe , which recommends pasting chunk format into a workspace. What are the tradeoffs with this approach? We could cross-link the two, explaining the tradeoffs, or eliminate one...

Thanks!
Cheers,
Sean
Reply | Threaded
Open this post in threaded view
|

Re: Porting code from other Smalltalks

Sean P. DeNigris
Administrator
Sean P. DeNigris wrote
So I'm assuming that porting into the same namespace as the rest of the project is best practice. If so, should we add that (i.e. using amberc -n) to those instructions?
Bump. Adding that by "porting" I mean code that will be developed/versioned/maintained in another Smalltalk and then compiled to js to be used in Amber. Should these objects be added to the project namespace by default?
Cheers,
Sean
Reply | Threaded
Open this post in threaded view
|

Re: Porting code from other Smalltalks

Benjamin Van Ryseghem-2
I am also interested to know that since I will port Spec to Amber, but I would love to have a
common code base with Pharo plus some extra

Ben

On 17 Apr 2014, at 20:17, Sean P. DeNigris <[hidden email]> wrote:

> Sean P. DeNigris wrote
>> So I'm assuming that porting into the same namespace as the rest of the
>> project is best practice. If so, should we add that (i.e. using amberc -n)
>> to those instructions?
>
> Bump. Adding that by "porting" I mean code that will be
> developed/versioned/maintained in another Smalltalk and then compiled to js
> to be used in Amber. Should these objects be added to the project namespace
> by default?
>
>
>
> -----
> Cheers,
> Sean
> --
> View this message in context: http://forum.world.st/Porting-code-from-other-Smalltalks-tp4754936p4755158.html
> Sent from the Amber Smalltalk mailing list archive at Nabble.com.
>
> --
> You received this message because you are subscribed to the Google Groups "amber-lang" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
> For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "amber-lang" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Porting code from other Smalltalks

philippeback
This would really provide a big plus in terms of code reusability.

Domain models included.

Phil

On Fri, Apr 18, 2014 at 10:22 AM, Benjamin Van Ryseghem <[hidden email]> wrote:
I am also interested to know that since I will port Spec to Amber, but I would love to have a
common code base with Pharo plus some extra

Ben

On 17 Apr 2014, at 20:17, Sean P. DeNigris <[hidden email]> wrote:

> Sean P. DeNigris wrote
>> So I'm assuming that porting into the same namespace as the rest of the
>> project is best practice. If so, should we add that (i.e. using amberc -n)
>> to those instructions?
>
> Bump. Adding that by "porting" I mean code that will be
> developed/versioned/maintained in another Smalltalk and then compiled to js
> to be used in Amber. Should these objects be added to the project namespace
> by default?
>
>
>
> -----
> Cheers,
> Sean
> --
> View this message in context: http://forum.world.st/Porting-code-from-other-Smalltalks-tp4754936p4755158.html
> Sent from the Amber Smalltalk mailing list archive at Nabble.com.
>
> --
> You received this message because you are subscribed to the Google Groups "amber-lang" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
> For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "amber-lang" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "amber-lang" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Porting code from other Smalltalks

Nicolas Petton
In reply to this post by Sean P. DeNigris
Hi!

Porting code from Pharo is not as easy as it should. Both wiki pages
seem a bit outdated and the Chunk importer in Amber misses some
compatibility methods to make the process a breeze.

I could take a couple of hours to improve the situation and take the
opportunity to update the doc if you guys think (and you'd be right)
that it's worth it.

Even better, I could to a remote pair programming session on the topic
if someone wants to join :)

Cheers,
Nico


Sean P. DeNigris writes:

> To port a package from Pharo 3.0 to Amber, I followed the instructions at
> https://github.com/amber-smalltalk/amber/wiki/Porting-code-from-other-Smalltalk-dialects
>
> I then added "" to my index.html. However, when I tried to open Helios, I
> got "JavaScript exception: TypeError: undefined is not a function"
>
> Noticing that amberc had put my packages in the amber_core namespace, I
> changed it to the namespace of my project, and then everything worked as
> expected.
>
> So I'm assuming that porting into the same namespace as the rest of the
> project is best practice. If so, should we add that (i.e. using amberc -n)
> to those instructions?
>
> Also, a more minor point. There are alternate instructions on porting code
> at https://github.com/amber-smalltalk/amber/wiki/Filing-in-code-recipe ,
> which recommends pasting chunk format into a workspace. What are the
> tradeoffs with this approach? We could cross-link the two, explaining the
> tradeoffs, or eliminate one...
>
> Thanks!
>
>
>
> -----
> Cheers,
> Sean
> --
> View this message in context: http://forum.world.st/Porting-code-from-other-Smalltalks-tp4754936.html
> Sent from the Amber Smalltalk mailing list archive at Nabble.com.


--
Nicolas Petton
http://nicolas-petton.fr

--
You received this message because you are subscribed to the Google Groups "amber-lang" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Porting code from other Smalltalks

Benjamin Van Ryseghem-2
I am in :)

Ben

On 18 Apr 2014, at 11:17, Nicolas Petton <[hidden email]> wrote:

> Hi!
>
> Porting code from Pharo is not as easy as it should. Both wiki pages
> seem a bit outdated and the Chunk importer in Amber misses some
> compatibility methods to make the process a breeze.
>
> I could take a couple of hours to improve the situation and take the
> opportunity to update the doc if you guys think (and you'd be right)
> that it's worth it.
>
> Even better, I could to a remote pair programming session on the topic
> if someone wants to join :)
>
> Cheers,
> Nico
>
>
> Sean P. DeNigris writes:
>
>> To port a package from Pharo 3.0 to Amber, I followed the instructions at
>> https://github.com/amber-smalltalk/amber/wiki/Porting-code-from-other-Smalltalk-dialects
>>
>> I then added "" to my index.html. However, when I tried to open Helios, I
>> got "JavaScript exception: TypeError: undefined is not a function"
>>
>> Noticing that amberc had put my packages in the amber_core namespace, I
>> changed it to the namespace of my project, and then everything worked as
>> expected.
>>
>> So I'm assuming that porting into the same namespace as the rest of the
>> project is best practice. If so, should we add that (i.e. using amberc -n)
>> to those instructions?
>>
>> Also, a more minor point. There are alternate instructions on porting code
>> at https://github.com/amber-smalltalk/amber/wiki/Filing-in-code-recipe ,
>> which recommends pasting chunk format into a workspace. What are the
>> tradeoffs with this approach? We could cross-link the two, explaining the
>> tradeoffs, or eliminate one...
>>
>> Thanks!
>>
>>
>>
>> -----
>> Cheers,
>> Sean
>> --
>> View this message in context: http://forum.world.st/Porting-code-from-other-Smalltalks-tp4754936.html
>> Sent from the Amber Smalltalk mailing list archive at Nabble.com.
>
>
> --
> Nicolas Petton
> http://nicolas-petton.fr
>
> --
> You received this message because you are subscribed to the Google Groups "amber-lang" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
> For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "amber-lang" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Porting code from other Smalltalks

Manfred Kröhnert
Once all the Grunt stuff has been sorted to work as planned it should ideally work the following way:

1. export/file-out Smalltalk code (eventually do some Amber specific cleanup first)
2. create a Gruntfile.js where you load the amberc task (from the new amber-dev repo) and compile the exported sources on the cli
3. load the generated files in your Amber project

This is how I imagine that it could work.
Other people might think differently and if so we should discuss this here and pull in the same direction.

Best,
Manfred



On Fri, Apr 18, 2014 at 1:21 PM, Benjamin Van Ryseghem <[hidden email]> wrote:
I am in :)

Ben

On 18 Apr 2014, at 11:17, Nicolas Petton <[hidden email]> wrote:

> Hi!
>
> Porting code from Pharo is not as easy as it should. Both wiki pages
> seem a bit outdated and the Chunk importer in Amber misses some
> compatibility methods to make the process a breeze.
>
> I could take a couple of hours to improve the situation and take the
> opportunity to update the doc if you guys think (and you'd be right)
> that it's worth it.
>
> Even better, I could to a remote pair programming session on the topic
> if someone wants to join :)
>
> Cheers,
> Nico
>
>
> Sean P. DeNigris writes:
>
>> To port a package from Pharo 3.0 to Amber, I followed the instructions at
>> https://github.com/amber-smalltalk/amber/wiki/Porting-code-from-other-Smalltalk-dialects
>>
>> I then added "" to my index.html. However, when I tried to open Helios, I
>> got "JavaScript exception: TypeError: undefined is not a function"
>>
>> Noticing that amberc had put my packages in the amber_core namespace, I
>> changed it to the namespace of my project, and then everything worked as
>> expected.
>>
>> So I'm assuming that porting into the same namespace as the rest of the
>> project is best practice. If so, should we add that (i.e. using amberc -n)
>> to those instructions?
>>
>> Also, a more minor point. There are alternate instructions on porting code
>> at https://github.com/amber-smalltalk/amber/wiki/Filing-in-code-recipe ,
>> which recommends pasting chunk format into a workspace. What are the
>> tradeoffs with this approach? We could cross-link the two, explaining the
>> tradeoffs, or eliminate one...
>>
>> Thanks!
>>
>>
>>
>> -----
>> Cheers,
>> Sean
>> --
>> View this message in context: http://forum.world.st/Porting-code-from-other-Smalltalks-tp4754936.html
>> Sent from the Amber Smalltalk mailing list archive at Nabble.com.
>
>
> --
> Nicolas Petton
> http://nicolas-petton.fr
>
> --
> You received this message because you are subscribed to the Google Groups "amber-lang" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
> For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "amber-lang" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "amber-lang" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.