Next: Group Parameters, Previous: Marking Groups, Up: Group Buffer

### 2.9 Foreign Groups

If you recall how to subscribe to servers (see Finding the News) you will remember that `gnus-secondary-select-methods` and `gnus-select-method` let you write a definition in Emacs Lisp of what servers you want to see when you start up. The alternate approach is to use foreign servers and groups. “Foreign” here means they are not coming from the select methods. All foreign server configuration and subscriptions are stored only in the `~/.newsrc.eld` file.

Below are some group mode commands for making and editing general foreign groups, as well as commands to ease the creation of a few special-purpose groups. All these commands insert the newly created groups under point—`gnus-subscribe-newsgroup-method` is not consulted.

Changes from the group editing commands are stored in `~/.newsrc.eld` (`gnus-startup-file`). An alternative is the variable `gnus-parameters`, See Group Parameters.

`G m`
  Make a new group (`gnus-group-make-group`). Gnus will prompt you for a name, a method and possibly an address. For an easier way to subscribe to NNTP groups (see Browse Foreign Server).
`G M`
  Make an ephemeral group (`gnus-group-read-ephemeral-group`). Gnus will prompt you for a name, a method and an address.
`G r`
  Rename the current group to something else (`gnus-group-rename-group`). This is valid only on some groups—mail groups mostly. This command might very well be quite slow on some back ends.
`G c`
  Customize the group parameters (`gnus-group-customize`).
`G e`
  Enter a buffer where you can edit the select method of the current group (`gnus-group-edit-group-method`).
`G p`
  Enter a buffer where you can edit the group parameters (`gnus-group-edit-group-parameters`).
`G E`
  Enter a buffer where you can edit the group info (`gnus-group-edit-group`).
`G d`
  Make a directory group (see Directory Groups). You will be prompted for a directory name (`gnus-group-make-directory-group`).
`G h`
  Make the Gnus help group (`gnus-group-make-help-group`).
`G D`
  Read an arbitrary directory as if it were a newsgroup with the `nneething` back end (`gnus-group-enter-directory`). See Anything Groups.
`G f`
  Make a group based on some file or other (`gnus-group-make-doc-group`). If you give a prefix to this command, you will be prompted for a file name and a file type. Currently supported types are `mbox`, `babyl`, `digest`, `news`, `rnews`, `mmdf`, `forward`, `rfc934`, `rfc822-forward`, `mime-parts`, `standard-digest`, `slack-digest`, `clari-briefs`, `nsmail`, `outlook`, `oe-dbx`, and `mailman`. If you run this command without a prefix, Gnus will guess at the file type. See Document Groups.
`G u`
  Create one of the groups mentioned in `gnus-useful-groups` (`gnus-group-make-useful-group`).
`G w`
  Make an ephemeral group based on a web search (`gnus-group-make-web-group`). If you give a prefix to this command, make a solid group instead. You will be prompted for the search engine type and the search string. Valid search engine types include `google`, `dejanews`, and `gmane`. See Web Searches.

  If you use the `google` search engine, you can limit the search to a particular group by using a match string like ‘`shaving group:alt.sysadmin.recovery`’.

`G R`
  Make a group based on an RSS feed (`gnus-group-make-rss-group`). You will be prompted for an URL. See RSS.
`G DEL`
  This function will delete the current group (`gnus-group-delete-group`). If given a prefix, this function will actually delete all the articles in the group, and forcibly remove the group itself from the face of the Earth. Use a prefix only if you are absolutely sure of what you are doing. This command can't be used on read-only groups (like `nntp` groups), though.
`G V`
  Make a new, fresh, empty `nnvirtual` group (`gnus-group-make-empty-virtual`). See Virtual Groups.
`G v`
  Add the current group to an `nnvirtual` group (`gnus-group-add-to-virtual`). Uses the process/prefix convention.

See Select Methods, for more information on the various select methods.

If `gnus-activate-foreign-newsgroups` is a positive number, Gnus will check all foreign groups with this level or lower at startup. This might take quite a while, especially if you subscribe to lots of groups from different NNTP servers. Also see Group Levels; `gnus-activate-level` also affects activation of foreign newsgroups.

The following commands create ephemeral groups. They can be called not only from the Group buffer, but in any Gnus buffer.

`gnus-read-ephemeral-gmane-group`
  Read an ephemeral group on Gmane.org. The articles are downloaded via HTTP using the URL specified by `gnus-gmane-group-download-format`. Gnus will prompt you for a group name, the start article number and an the article range.
`gnus-read-ephemeral-gmane-group-url`
  This command is similar to `gnus-read-ephemeral-gmane-group`, but the group name and the article number and range are constructed from a given URL. Supported URL formats include e.g. http://thread.gmane.org/gmane.foo.bar/12300/focus=12399, http://thread.gmane.org/gmane.foo.bar/12345/, http://article.gmane.org/gmane.foo.bar/12345/, http://permalink.gmane.org/gmane.foo.bar/12345/, and http://news.gmane.org/group/gmane.foo.bar/thread=12345.
`gnus-read-ephemeral-emacs-bug-group`
  Read an Emacs bug report in an ephemeral group. Gnus will prompt for a bug number. The default is the number at point. The URL is specified in `gnus-bug-group-download-format-alist`.
`gnus-read-ephemeral-debian-bug-group`
  Read a Debian bug report in an ephemeral group. Analog to `gnus-read-ephemeral-emacs-bug-group`.

Some of these command are also useful for article buttons, See Article Buttons.

Here is an example:

         (require 'gnus-art)
         (add-to-list
          'gnus-button-alist
          '("#\\([0-9]+\\)\\>" 1
            (string-match "\\<emacs\\>" (or gnus-newsgroup-name ""))
            gnus-read-ephemeral-emacs-bug-group 1))