Mailinglist Archive: yast-devel (251 mails)

< Previous Next >
Re: [yast-devel] Example module for demonstration refactoring
On Mon, Jul 29, 2013 at 11:10:30AM +0200, Josef Reidinger wrote:
Hi,
as ruby conversion knocking on a door I want to make after conversion
small demonstration how ruby can improve code. I don't want write
hypothetical module but change real module. Does anyone have idea which
relative small ("network" is not small :) module can be used as
demonstration?

I plan to demonstrate things like advanced testing in ruby, represent
internal structures as objects or error handling with exceptions.

FWIW, here are line counts of ruby files from the result directory:

yast2 68044
ycp-ui-bindings 64301
storage 47056
network 37843
packager 27284
autoinstallation 26228
installation 20651
printer 17097
users 16302
slepos-system-manager 13585
product-creator 13228
sound 12281
mail 10999
tv 9850
add-on-creator 9672
country 9349
ldap-client 8947
ftp-server 8292
samba-server 7866
ldap-server 7825
firewall 7285
squid 7246
http-server 6863
inetd 6560
ntp-client 6328
update 6322
runlevel 5793
restore 5576
core 5493
sysconfig 5228
heartbeat 5109
iscsi-lio-server 4914
wagon 4732
security 4574
registration 4528
scanner 4515
iscsi-client 4412
nis-server 4221
fcoe-client 4072
instserver 4045
add-on 3742
kerberos-client 3589
kerberos-server 3453
samba-client 3450
iscsi-server 3310
sudo 3294
metapackage 3218
nis-client 3195
nfs-server 3011
profile-manager 2989
slp-server 2840
support 2768
proxy 2665
online-update 2591
reipl 2547
power-management 2519
certify 2353
isns 2333
snapper 2257
drbd 2145
sshd 2011
firstboot 1823
pos-installation 1814
online-update-configuration 1683
openvas-security-scanner 1648
phone-services 1604
mouse 1441
squidguard 1385
live-installer 1370
rear 1310
lxc 1166
fingerprint-reader 1135
hpc 1048
dirinstall 1040
tftp-server 1011
multipath 950
irda 826
repair 564
rdp 563
devtools 558
slp 498
pam 417
mail-server 283
transfer 266
testsuite 255
perl-bindings 236
online-update-test 73
crowbar 51
slepos-image-builder 20
iplb 15
you-server 0
vm 0
ui-qt-tests 0
tune 0
theme 0
s390 0
system-profile 0
nfs-client 0
kdump 0
hardware-detection 0
dns-server 0
dhcp-server 0
dbus-server 0
cluster 0
ca-management 0
boot-server 0
bootloader 0
backup 0
autofs 0
audit-laf 0
apparmor 0

Code:

cd ~/.local/share/ycp-killer/result
for i in *; do printf "%-30s" $i; find $i -name \*rb | xargs cat | wc -l; done
| sort -k2 -nr

--
Martin Vidner, Cloud & Systems Management Team
http://en.opensuse.org/User:Mvidner

Kuracke oddeleni v restauraci je jako fekalni oddeleni v bazenu
< Previous Next >
Follow Ups
References