kintesh / containerise

Firefox extension to automatically open websites in a container
MIT License
418 stars 53 forks source link

Allow assigning patterns to temporary containers #59

Open madduck opened 5 years ago

madduck commented 5 years ago

At the moment, I have to use Temporary Containers in addition to Containerise, but that is only because Containerise is missing the one feature I need from TO: temporary containers. It'd be awesome if I could e.g. create a rule like:

@(.+\.)*google(\..+)+ , TMP

which would then result in a new container be created every time I visit a matching website. The temporary containers would need to be cleaned up as well when the last tab is closed, and on domain change.

stoically commented 5 years ago

Instead of re-inventing the wheel, it would also be possible to call TCs API to let it create and handle TCs.

However, TC supports Per-Domain Isolation rules which also take RegExps - which would achieve exactly what you're asking for here.

As a side-note, you might want to reconsider your regexp, since it would e.g. also match example.com/?q=google.com or google.example.com. Maybe something like ^https?://([^/]+\.)?google\.[^./]+ (would not match google domains with two-level TLDs like co.uk, to achieve that those would all need to matched exactly by specifying them).

madduck commented 5 years ago

I am using TC as well as Containerise, and I'd appreciate being able to unify those two. Yes, the regexp needs work, it was just quick'n'dirty for this issue…

ghost commented 5 years ago

I'm not sure about requiring the installation of another addon to make a feature work. If @kintesh is ok with it, then sure, let's do it that way. However it isn't difficult to implement it ourselves

madduck commented 4 years ago

The "default containers" feature, with a container name such as t{ms} goes part of the way here. The problem now is that every link I click will result in a new container. I could use the {domain} variable instead of {ms}, but it's also not that easy.

I think if #53 were solved, then this would be done, i.e. while I am in a container, I just stay in a container, but only when I open a new tab, then the container rules get applied.

go2null commented 4 years ago

@madduck

I could use the {domain} variable instead of {ms}, but it's also not that easy.

I use {domain}.tmp as my Default Container. What is the issue with using that?

madduck commented 4 years ago

The issue with that, @go2null, is that some websites span domains, and break if these domains are put into different containers. As such, this is related to #33.

geeknik commented 3 years ago

Voting for a 'Temporary Containers' feature since the actual Temporary Containers extension appears to be broken with release and nightly versions of Firefox. 👍🏻