Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.soft-sys.math.mathematica > #4105

Re: Is it possible to delete "context" from the list of loaded Contexts[]?

From Bill Rowe <readnews@sbcglobal.net>
Newsgroups comp.soft-sys.math.mathematica
Subject Re: Is it possible to delete "context" from the list of loaded Contexts[]?
Date 2011-07-31 11:31 +0000
Organization Steven M. Christensen and Associates, Inc and MathTensor, Inc.
Message-ID <j13eff$56g$1@smc.vnet.net> (permalink)

Show all headers | View raw


On 7/29/11 at 8:02 AM, lehin.p@gmail.com (Alexey Popkov) wrote:


>We can remove all symbols in a particular context by using
>Remove["context`*"]. But is it possible to remove "context`" itself
>from the system so that it will no longer be listed in Contexts[]?

Yes. The simplest way to do this would be to load the package
CleanSlate before defining the context you want to remove. That
is doing:

<<Utilities`CleanSlate`

followed by

CleanSlate[]

will remove everything defined after CleanSlate was loaded. Or
if you just want to remove one context

CleanSlate["context`"]

will do that.

The file CleanSlate.m can be found at

ToFileName[{$InstallationDirectory,"AddOns","ExtraPackages","Utilities"}]

That file is well commented to describe how CleanSlate works. If
the functions provided aren't what you need, it should form a
good basis for creating your own solution.

Back to comp.soft-sys.math.mathematica | Previous | Next | Find similar | Unroll thread


Thread

Re: Is it possible to delete "context" from the list of loaded Contexts[]? Bill Rowe <readnews@sbcglobal.net> - 2011-07-31 11:31 +0000

csiph-web