You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@felix.apache.org by Cristiano Gavião <cv...@gmail.com> on 2014/06/10 15:05:10 UTC

[Gogo] can I override gosh_profile with a fragment?

Hello,

I would like to add a banner at gogo session console.

I discovered that gosh_profile and motd are the files that I need to 
deal with.

Would be possible to override gosh_profile and add motd using a bundle 
fragment instead of define a gosh.home?

thanks,

Cristiano

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
For additional commands, e-mail: users-help@felix.apache.org


Re: [Gogo] can I override gosh_profile with a fragment?

Posted by Cristiano Gavião <cv...@gmail.com>.
:D

On 10-06-2014 19:48, Raymond Auge wrote:
> Hahaha... nice PR Cristiano!
>
> :P
>
>
> On Tue, Jun 10, 2014 at 10:38 AM, Raymond Auge <ra...@liferay.com>
> wrote:
>
>> I often wish there was a convention in OSGi that was to (transparently)
>> look up:
>>
>> /ext/<resource_path>
>>
>> before looking up
>>
>> /<resource_path>
>>
>> This way, you could extend the resources of any bundle simply by attaching
>> a fragment with resources at /ext.
>>
>> I'm fairly certain that in our environment we'll soon end up with a
>> framework hook which enables this by default.
>>
>> - Ray
>>
>>
>> On Tue, Jun 10, 2014 at 10:06 AM, Cristiano Gavião <cv...@gmail.com>
>> wrote:
>>
>>> Hi Derek,
>>>
>>> I took a look at the source and the current directory actually is the
>>> "user.dir".
>>>
>>> I can't use external directories in file system. seems that the only way
>>> will be repackage this bundle...
>>>
>>> thanks
>>>
>>>
>>> On 10-06-2014 10:34, Derek Baum wrote:
>>>
>>>> gosh_profile is located as follows:
>>>>
>>>> in “etc” directory in filesystem, relative to current directory
>>>> or if “gosh.home” is set, then relative to “gosh.home”
>>>> as resource embedded in gogo.shell bundle.
>>>>
>>>> Once located, gogo_profile controls gogo initialisation, and the default
>>>> gosh_profile prints the banner from “motd” relative to “gosh_profile”.
>>>>
>>>> You can customise gosh_profile (and thus motd) by installed them in an
>>>> “etc” directory relative to current directory or “gosh.home”.
>>>>
>>>> I don’t think a fragment bundle can override the gosh_profile resource
>>>> in its host bundle.
>>>>
>>>> —
>>>> Derek
>>>>
>>>>
>>>>
>>>> On 10 Jun 2014, at 14:05, Cristiano Gavião <cv...@gmail.com> wrote:
>>>>
>>>>   Hello,
>>>>> I would like to add a banner at gogo session console.
>>>>>
>>>>> I discovered that gosh_profile and motd are the files that I need to
>>>>> deal with.
>>>>>
>>>>> Would be possible to override gosh_profile and add motd using a bundle
>>>>> fragment instead of define a gosh.home?
>>>>>
>>>>> thanks,
>>>>>
>>>>> Cristiano
>>>>>
>>>>> ---------------------------------------------------------------------
>>>>> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
>>>>> For additional commands, e-mail: users-help@felix.apache.org
>>>>>
>>>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
>>> For additional commands, e-mail: users-help@felix.apache.org
>>>
>>>
>>
>> --
>> *Raymond Augé* <http://www.liferay.com/web/raymond.auge/profile>
>>   (@rotty3000)
>> Senior Software Architect
>> *Liferay, Inc.* <http://www.liferay.com> (@Liferay)
>>
>>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
For additional commands, e-mail: users-help@felix.apache.org


Re: [Gogo] can I override gosh_profile with a fragment?

Posted by Raymond Auge <ra...@liferay.com>.
Hahaha... nice PR Cristiano!

:P


On Tue, Jun 10, 2014 at 10:38 AM, Raymond Auge <ra...@liferay.com>
wrote:

> I often wish there was a convention in OSGi that was to (transparently)
> look up:
>
> /ext/<resource_path>
>
> before looking up
>
> /<resource_path>
>
> This way, you could extend the resources of any bundle simply by attaching
> a fragment with resources at /ext.
>
> I'm fairly certain that in our environment we'll soon end up with a
> framework hook which enables this by default.
>
> - Ray
>
>
> On Tue, Jun 10, 2014 at 10:06 AM, Cristiano Gavião <cv...@gmail.com>
> wrote:
>
>> Hi Derek,
>>
>> I took a look at the source and the current directory actually is the
>> "user.dir".
>>
>> I can't use external directories in file system. seems that the only way
>> will be repackage this bundle...
>>
>> thanks
>>
>>
>> On 10-06-2014 10:34, Derek Baum wrote:
>>
>>> gosh_profile is located as follows:
>>>
>>> in “etc” directory in filesystem, relative to current directory
>>> or if “gosh.home” is set, then relative to “gosh.home”
>>> as resource embedded in gogo.shell bundle.
>>>
>>> Once located, gogo_profile controls gogo initialisation, and the default
>>> gosh_profile prints the banner from “motd” relative to “gosh_profile”.
>>>
>>> You can customise gosh_profile (and thus motd) by installed them in an
>>> “etc” directory relative to current directory or “gosh.home”.
>>>
>>> I don’t think a fragment bundle can override the gosh_profile resource
>>> in its host bundle.
>>>
>>> —
>>> Derek
>>>
>>>
>>>
>>> On 10 Jun 2014, at 14:05, Cristiano Gavião <cv...@gmail.com> wrote:
>>>
>>>  Hello,
>>>>
>>>> I would like to add a banner at gogo session console.
>>>>
>>>> I discovered that gosh_profile and motd are the files that I need to
>>>> deal with.
>>>>
>>>> Would be possible to override gosh_profile and add motd using a bundle
>>>> fragment instead of define a gosh.home?
>>>>
>>>> thanks,
>>>>
>>>> Cristiano
>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
>>>> For additional commands, e-mail: users-help@felix.apache.org
>>>>
>>>>
>>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
>> For additional commands, e-mail: users-help@felix.apache.org
>>
>>
>
>
> --
> *Raymond Augé* <http://www.liferay.com/web/raymond.auge/profile>
>  (@rotty3000)
> Senior Software Architect
> *Liferay, Inc.* <http://www.liferay.com> (@Liferay)
>
>


-- 
*Raymond Augé* <http://www.liferay.com/web/raymond.auge/profile>
 (@rotty3000)
Senior Software Architect
*Liferay, Inc.* <http://www.liferay.com> (@Liferay)

Re: [Gogo] can I override gosh_profile with a fragment?

Posted by Cristiano Gavião <cv...@gmail.com>.
Great idea Raymond ! :D

On 10-06-2014 11:38, Raymond Auge wrote:
> I often wish there was a convention in OSGi that was to (transparently)
> look up:
>
> /ext/<resource_path>
>
> before looking up
>
> /<resource_path>
>
> This way, you could extend the resources of any bundle simply by attaching
> a fragment with resources at /ext.
>
> I'm fairly certain that in our environment we'll soon end up with a
> framework hook which enables this by default.
>
> - Ray
>
>
> On Tue, Jun 10, 2014 at 10:06 AM, Cristiano Gavião <cv...@gmail.com>
> wrote:
>
>> Hi Derek,
>>
>> I took a look at the source and the current directory actually is the
>> "user.dir".
>>
>> I can't use external directories in file system. seems that the only way
>> will be repackage this bundle...
>>
>> thanks
>>
>>
>> On 10-06-2014 10:34, Derek Baum wrote:
>>
>>> gosh_profile is located as follows:
>>>
>>> in “etc” directory in filesystem, relative to current directory
>>> or if “gosh.home” is set, then relative to “gosh.home”
>>> as resource embedded in gogo.shell bundle.
>>>
>>> Once located, gogo_profile controls gogo initialisation, and the default
>>> gosh_profile prints the banner from “motd” relative to “gosh_profile”.
>>>
>>> You can customise gosh_profile (and thus motd) by installed them in an
>>> “etc” directory relative to current directory or “gosh.home”.
>>>
>>> I don’t think a fragment bundle can override the gosh_profile resource in
>>> its host bundle.
>>>
>>> —
>>> Derek
>>>
>>>
>>>
>>> On 10 Jun 2014, at 14:05, Cristiano Gavião <cv...@gmail.com> wrote:
>>>
>>>   Hello,
>>>> I would like to add a banner at gogo session console.
>>>>
>>>> I discovered that gosh_profile and motd are the files that I need to
>>>> deal with.
>>>>
>>>> Would be possible to override gosh_profile and add motd using a bundle
>>>> fragment instead of define a gosh.home?
>>>>
>>>> thanks,
>>>>
>>>> Cristiano
>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
>>>> For additional commands, e-mail: users-help@felix.apache.org
>>>>
>>>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
>> For additional commands, e-mail: users-help@felix.apache.org
>>
>>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
For additional commands, e-mail: users-help@felix.apache.org


Re: [Gogo] can I override gosh_profile with a fragment?

Posted by Raymond Auge <ra...@liferay.com>.
I often wish there was a convention in OSGi that was to (transparently)
look up:

/ext/<resource_path>

before looking up

/<resource_path>

This way, you could extend the resources of any bundle simply by attaching
a fragment with resources at /ext.

I'm fairly certain that in our environment we'll soon end up with a
framework hook which enables this by default.

- Ray


On Tue, Jun 10, 2014 at 10:06 AM, Cristiano Gavião <cv...@gmail.com>
wrote:

> Hi Derek,
>
> I took a look at the source and the current directory actually is the
> "user.dir".
>
> I can't use external directories in file system. seems that the only way
> will be repackage this bundle...
>
> thanks
>
>
> On 10-06-2014 10:34, Derek Baum wrote:
>
>> gosh_profile is located as follows:
>>
>> in “etc” directory in filesystem, relative to current directory
>> or if “gosh.home” is set, then relative to “gosh.home”
>> as resource embedded in gogo.shell bundle.
>>
>> Once located, gogo_profile controls gogo initialisation, and the default
>> gosh_profile prints the banner from “motd” relative to “gosh_profile”.
>>
>> You can customise gosh_profile (and thus motd) by installed them in an
>> “etc” directory relative to current directory or “gosh.home”.
>>
>> I don’t think a fragment bundle can override the gosh_profile resource in
>> its host bundle.
>>
>> —
>> Derek
>>
>>
>>
>> On 10 Jun 2014, at 14:05, Cristiano Gavião <cv...@gmail.com> wrote:
>>
>>  Hello,
>>>
>>> I would like to add a banner at gogo session console.
>>>
>>> I discovered that gosh_profile and motd are the files that I need to
>>> deal with.
>>>
>>> Would be possible to override gosh_profile and add motd using a bundle
>>> fragment instead of define a gosh.home?
>>>
>>> thanks,
>>>
>>> Cristiano
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
>>> For additional commands, e-mail: users-help@felix.apache.org
>>>
>>>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
> For additional commands, e-mail: users-help@felix.apache.org
>
>


-- 
*Raymond Augé* <http://www.liferay.com/web/raymond.auge/profile>
 (@rotty3000)
Senior Software Architect
*Liferay, Inc.* <http://www.liferay.com> (@Liferay)

Re: [Gogo] can I override gosh_profile with a fragment?

Posted by Cristiano Gavião <cv...@gmail.com>.
Hi Derek,

I took a look at the source and the current directory actually is the 
"user.dir".

I can't use external directories in file system. seems that the only way 
will be repackage this bundle...

thanks

On 10-06-2014 10:34, Derek Baum wrote:
> gosh_profile is located as follows:
>
> in “etc” directory in filesystem, relative to current directory
> or if “gosh.home” is set, then relative to “gosh.home”
> as resource embedded in gogo.shell bundle.
>
> Once located, gogo_profile controls gogo initialisation, and the default gosh_profile prints the banner from “motd” relative to “gosh_profile”.
>
> You can customise gosh_profile (and thus motd) by installed them in an “etc” directory relative to current directory or “gosh.home”.
>
> I don’t think a fragment bundle can override the gosh_profile resource in its host bundle.
>
> —
> Derek
>
>
>
> On 10 Jun 2014, at 14:05, Cristiano Gavião <cv...@gmail.com> wrote:
>
>> Hello,
>>
>> I would like to add a banner at gogo session console.
>>
>> I discovered that gosh_profile and motd are the files that I need to deal with.
>>
>> Would be possible to override gosh_profile and add motd using a bundle fragment instead of define a gosh.home?
>>
>> thanks,
>>
>> Cristiano
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
>> For additional commands, e-mail: users-help@felix.apache.org
>>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
For additional commands, e-mail: users-help@felix.apache.org


Re: [Gogo] can I override gosh_profile with a fragment?

Posted by Derek Baum <de...@baums.org.uk>.
gosh_profile is located as follows:

in “etc” directory in filesystem, relative to current directory
or if “gosh.home” is set, then relative to “gosh.home”
as resource embedded in gogo.shell bundle.

Once located, gogo_profile controls gogo initialisation, and the default gosh_profile prints the banner from “motd” relative to “gosh_profile”.

You can customise gosh_profile (and thus motd) by installed them in an “etc” directory relative to current directory or “gosh.home”.

I don’t think a fragment bundle can override the gosh_profile resource in its host bundle.

—
Derek



On 10 Jun 2014, at 14:05, Cristiano Gavião <cv...@gmail.com> wrote:

> Hello,
> 
> I would like to add a banner at gogo session console.
> 
> I discovered that gosh_profile and motd are the files that I need to deal with.
> 
> Would be possible to override gosh_profile and add motd using a bundle fragment instead of define a gosh.home?
> 
> thanks,
> 
> Cristiano
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
> For additional commands, e-mail: users-help@felix.apache.org
>