[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] master b673e3a 63/76: Added default setup and removed experimenta
From: |
Ian Dunn |
Subject: |
[elpa] master b673e3a 63/76: Added default setup and removed experimental WPA supplicant backend. |
Date: |
Thu, 23 Feb 2017 19:42:54 -0500 (EST) |
branch: master
commit b673e3a1991257483e0d0185537e0da19e93a1dc
Author: Ian Dunn <address@hidden>
Commit: Ian Dunn <address@hidden>
Added default setup and removed experimental WPA supplicant backend.
---
lisp/enwc-setup.el | 59 ++++++++++++++++++++++++++++++++++++++++++
lisp/enwc-wpa.el | 76 ------------------------------------------------------
2 files changed, 59 insertions(+), 76 deletions(-)
diff --git a/lisp/enwc-setup.el b/lisp/enwc-setup.el
new file mode 100644
index 0000000..5c463c7
--- /dev/null
+++ b/lisp/enwc-setup.el
@@ -0,0 +1,59 @@
+;; enwc-setup.el - Setup routines for ENWC
+
+;; Copyright (C) 2012-2014 Free Software Foundation, Inc.
+
+;; Author: Ian Dunn <address@hidden>
+;; Keywords: network, wicd, manager, nm
+;; Version: 2.0
+;; Homepage: https://savannah.nongnu.org/p/enwc
+
+;; This file is part of GNU Emacs.
+
+;; GNU Emacs is free software; you can redistribute it and/or modify it
+;; under the terms of the GNU General Public License as published by
+;; the Free Software Foundation; either version 3, or (at your option)
+;; any later version.
+
+;; GNU Emacs is distributed in the hope that it will be useful, but WITHOUT
+;; ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
+;; or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
+;; License for more details.
+
+;; You should have received a copy of the GNU General Public License
+;; along with GNU Emacs; see the file COPYING. If not, write to the Free
+;; Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+;; 02110-1301, USA.
+
+;;; Commentary:
+
+;;; Code:
+
+(require 'enwc)
+(require 'enwc-backend)
+(require 'enwc-wicd)
+(require 'enwc-nm)
+
+;;;###autoload
+(defun enwc-setup ()
+ "Set up ENWC.
+This sets up ENWC and confirms that one of the backends can be found on D-Bus."
+ (when enwc-display-mode-line
+ (enwc-enable-display-mode-line))
+
+ (when (and enwc-auto-scan
+ (> enwc-auto-scan-interval 0)
+ (not enwc-scan-timer))
+ (setq enwc-scan-timer
+ (run-at-time t enwc-auto-scan-interval 'enwc-scan t)))
+
+ (let ((back-list enwc-backends)
+ cur-back pass)
+ (while (and back-list (not pass))
+ (setq cur-back (pop back-list))
+ (setq pass (ignore-errors (enwc-load-backend cur-back))))
+ (unless pass
+ (error "No usable backend was found."))))
+
+(provide 'enwc-setup)
+
+;;; enwc-setup.el ends here
diff --git a/lisp/enwc-wpa.el b/lisp/enwc-wpa.el
deleted file mode 100644
index 191ae71..0000000
--- a/lisp/enwc-wpa.el
+++ /dev/null
@@ -1,76 +0,0 @@
-;;; enwc-wpa.el --- Emacs Network Client WPA_CLI backend
-
-;; Copyright (C) 2012-2014 Free Software Foundation, Inc.
-
-;; Author: Ian Dunn <address@hidden>
-;; Keywords: external, network, wicd, manager, nm
-;; Version: 2.0
-;; Homepage: https://savannah.nongnu.org/p/enwc
-
-;; This file is part of GNU Emacs.
-
-;; GNU Emacs is free software; you can redistribute it and/or modify it
-;; under the terms of the GNU General Public License as published by
-;; the Free Software Foundation; either version 3, or (at your option)
-;; any later version.
-
-;; GNU Emacs is distributed in the hope that it will be useful, but WITHOUT
-;; ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
-;; or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
-;; License for more details.
-
-;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to the Free
-;; Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-;; 02110-1301, USA.
-
-;;; Commentary:
-;;
-;; Back-end driven by wpa_cli
-;;
-;; Requires root to use wpa_cli
-
-;;; Code:
-
-(require 'enwc)
-
-(defgroup enwc-wpa nil
- "Settings for wpa_cli back-end."
- :prefix "enwc-wpa-"
- :group 'enwc)
-
-(defcustom enwc-wpa-wpa-cli-program "/usr/bin/wpa_cli"
- "Name of the wpa_cli executable."
- :group 'enwc-wpa
- :type 'file)
-
-(defvar enwc-wpa--wpa-cli-buffer " *ENWC wpa_cli*")
-
-;; (defun enwc-wpa--run-wpa-cli (&rest args)
-;; ;; Allow us to go into root.
-;; (cd "/sudo::/")
-;; (setq args (append
-;; (list "-i" (if enwc-using-wired enwc-wired-device
enwc-wireless-device))
-;; args))
-;; (apply #'call-process "wpa_cli" nil enwc-wpa--wpa-cli-buffer nil args))
-
-
-;; Load/Unload
-
-(defun enwc-wpa-load ()
- ;; Start the wpa_cli process
- ;; Start the wpa_supplicant process if necessary
-)
-
-
-; ;;;;;;;;;; ;
-; ;; Scan ;; ;
-; ;;;;;;;;;; ;
-
-(defun enwc-wpa-scan ()
- "Run wpa_cli to get a scan"
- (enwc-wpa--run-wpa-cli "scan")
- ()
- )
-
-;;; enwc-wpa.el ends here
- [elpa] master ba6061b 51/76: Created more robust backend system., (continued)
- [elpa] master ba6061b 51/76: Created more robust backend system., Ian Dunn, 2017/02/23
- [elpa] master ad38333 59/76: Cleaned up enwc-refresh-widths and changed enwc-details-list to enwc-column-specs., Ian Dunn, 2017/02/23
- [elpa] master a46fe3c 64/76: Don't switch to the ENWC buffer when processing a scan., Ian Dunn, 2017/02/23
- [elpa] master 33515f8 66/76: Silenced byte-compiler., Ian Dunn, 2017/02/23
- [elpa] master bcb33e6 30/76: (enwc-get-networks): Improved docstring., Ian Dunn, 2017/02/23
- [elpa] master 245a82f 52/76: Moved Wicd and NetworkManager backends to new system., Ian Dunn, 2017/02/23
- [elpa] master 3b1bbc6 69/76: Fixed autoloads target in Makefile, Ian Dunn, 2017/02/23
- [elpa] master 8c17c8c 73/76: Updated hgignore to ignore elc files in top-level directory., Ian Dunn, 2017/02/23
- [elpa] master a3c59cc 74/76: Updated version to 2.0beta1, Ian Dunn, 2017/02/23
- [elpa] master 2e271c6 72/76: Moved lisp files into top-level directory., Ian Dunn, 2017/02/23
- [elpa] master b673e3a 63/76: Added default setup and removed experimental WPA supplicant backend.,
Ian Dunn <=
- [elpa] master 2c298fc 70/76: Updated copyright and keywords on all files., Ian Dunn, 2017/02/23
- [elpa] master 8e44368 68/76: Moved enwc-setup to enwc.el, and added it to enwc., Ian Dunn, 2017/02/23
- [elpa] master 4462fba 56/76: Lots of changes to enwc.el., Ian Dunn, 2017/02/23
- [elpa] master 62fe017 71/76: Removed some files from docs., Ian Dunn, 2017/02/23
- [elpa] master 942d83d 15/76: enwc.el, enwc-setup.el: Consolidated and concretely defined front-end interface., Ian Dunn, 2017/02/23
- [elpa] master 6417d2c 49/76: Correctly merged old branch., Ian Dunn, 2017/02/23
- [elpa] master eb6b085 11/76: Fixed up copyright information., Ian Dunn, 2017/02/23
- [elpa] master 218aa82 25/76: Fixed prefix of customization group., Ian Dunn, 2017/02/23
- [elpa] master c9a94c8 44/76: Added tag 2.0 for changeset 3e2cab525cbc, Ian Dunn, 2017/02/23
- [elpa] master c4ac6fc 60/76: Fixed bug in 'enwc-load-default-backend', Ian Dunn, 2017/02/23