Comments (4)
Could try to list all the devices in "/dev" then capture only /dev/sd* listings. (/dev/sda, /dev/sdb, /dev/sdc). But then after that validate that they are sd cards somehow.
Never ran into that issue before. let me see if I can replicate it.
And I'll test a few things out. Let me know if you come up with a solution and if we can add it.
from osid-python3.
from osid-python3.
listing all devices in /dev then looking for devices didn't seem very effective.
'sudo fdisk -l' did work for me though (l being lowercase L).
The backend should have started with the su crontab, so there shouldn't be any issues with root access. (hopefully)
on the snap side note, you can fork the code and port to whatever you want. I don't mind at all!
I have not heard of snap, just did a quick search, looks like scratch? Would love to see how that project turns out!
from osid-python3.
Note: found a solution in this question https://codereview.stackexchange.com/questions/152486/parsing-the-lsblk-output
using lsblk might be better, no root access needed. and can display just the disk names and size with the command "lsblk -d -o name,size -n". Will list the mmcblk0 (rpi disk) so will just have it ignore it.
from osid-python3.
Related Issues (5)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from osid-python3.